Interface: IAIProfile
Defined in: internal/ai-profile-store/types.ts:171
Tenant choices for one way of using AI. Passed as data to Assembler, ToolPolicy, LLMClient.
Properties
allowedTools
allowedTools:
string[]
Defined in: internal/ai-profile-store/types.ts:183
Tool names the LLM may see. Subset of ToolRegistry.
approvals
approvals:
string[]
Defined in: internal/ai-profile-store/types.ts:185
Tool names that pause for a human before execution.
cheapModelId?
optionalcheapModelId?:string
Defined in: internal/ai-profile-store/types.ts:181
Model for helper calls (memory, rewrite). Empty = platform default.
id
id:
string
Defined in: internal/ai-profile-store/types.ts:173
The tenant's own id of the profile; what a call names in profileId (D103).
limits
limits:
IAIProfileLimits
Defined in: internal/ai-profile-store/types.ts:249
The loop and output caps of the profile.
modelId
modelId:
string
Defined in: internal/ai-profile-store/types.ts:179
Main model; must exist and be enabled in ModelRegistry.
name
name:
string
Defined in: internal/ai-profile-store/types.ts:177
Human label, e.g. "Careful refunds".
parallelToolCalls?
optionalparallelToolCalls?:boolean
Defined in: internal/ai-profile-store/types.ts:217
The tool calls of one model step run at the same time (D101).
An agent step that looks up three things waits for the slowest, not for the sum.
A model that asks for several tools in one step gets no result before the step is out, so the calls are independent by
construction: the gateway decides every call first, runs every allowed one concurrently, stores the results in the
order of the request and pauses once with every call that needs a human. The calls of a tool whose policy is a
predicate are decided and run one by one after the others (D112): such a policy may read state the step changes, like
"already refunded", and must see the earlier calls. Switch it off for a profile whose tools
must not overlap (two writes to the same record, a rate-limited API): the calls then run one after the other, and a
call that needs a human pauses the run before the calls after it are decided.
Example
false - a chat profile whose tools write to one ledger and must not overlap
Default
true
promptAddendum
promptAddendum:
string
Defined in: internal/ai-profile-store/types.ts:233
Tenant text appended to the CHAT_MAIN system prompt.
reviewAnswers?
optionalreviewAnswers?:boolean
Defined in: internal/ai-profile-store/types.ts:199
Every answer of a run() on this profile waits for a human before the end user sees it (D99).
Gates the words, as
approvalsgates the actions: a moderator reads the reply, a clerk checks the drafted letter.
The run pauses with a RESULT_REVIEW envelope after the answer passed the output checks; the reviewer approves, edits or
rejects it through resume(). ask() on such a profile is refused: it has no run to pause. Leave it off for a chat whose
answers the user reads directly.
Example
true - a support bot whose replies an agent checks before the customer sees them
Default
false
skills?
optionalskills?:ISkill[]
Defined in: internal/ai-profile-store/types.ts:247
Instructions the model loads on demand on every call of this profile (D124).
A profile's long rules without paying for them on every call.
Listed by name and description in the system prompt of a run(), loaded with dyna_aigw_load_skill when a task needs one;
inlined whole in an ask(). Merged with the call's skills; a name present in both is a 400. Names must be unique
here too: upsertProfile refuses a duplicate.
Example
[{name: "refund_policy", description: "…", body: "…"}] - the shop's refund rules, read only when a refund comes up
Default
undefined - no skills
templateOverrides?
optionaltemplateOverrides?:Record<string,string>
Defined in: internal/ai-profile-store/types.ts:251
Reserved v2 seam: per-key template body overrides.
tenantId
tenantId:
string
Defined in: internal/ai-profile-store/types.ts:175
The tenant the profile belongs to; a profile is never visible to another tenant.
workingMemory?
optionalworkingMemory?:TWorkingMemoryStrategy
Defined in: internal/ai-profile-store/types.ts:231
How this profile's threads reach the model: raw sliding window or summary buffer.
One tenant, two bots: precise chat on one, cheap long threads on the other.
Overrides IWorkingMemoryConfig.strategy; IWorkingMemoryConfig.enabled stays gateway-wide. A thread keeps its
stored summary when the strategy switches: SLIDING_WINDOW ignores it, a switch back resumes from it.
Read by the built-in WorkingMemory; a host memory may read it or ignore it.
Example
{type: EWorkingMemoryStrategy.SLIDING_WINDOW} - a support chat whose answers must quote the user's own words
Default
undefined - the gateway's default strategy