Tool Use, LLMs, and IntegrationAccounts
Valor combines chat, tool execution, model routing, and product navigation. Its design goal is practical work with reviewable control.
Tool Classes
| Tool class | Examples | Guardrail |
|---|---|---|
| Read context | GrayMatter memory, object graph, workflow state, generated schemas | RBAC scoped reads only. |
| Draft artifacts | app schema, workflow graph, MCP publish payload, content copy | Show before committing when material. |
| Mutate system state | create workflow, update memory, create IntegrationAccount, publish MCP endpoint | Require clear user intent and server-side authorization. |
| External action | social post, email, payment, deployment, web action | Use IntegrationAccount permissions, audit, and preview when possible. |
IntegrationAccounts
IntegrationAccounts provide connection metadata and secret references for external systems. They are used by ExecModules, MCP endpoints, workflow tasks, and Valor-assisted actions.
Valor should never expose raw decrypted credentials in chat. It should show account labels, provider, capability, status, scopes, and owner/tenant context.
LLMDetails
LLMDetails is the model/provider contract for OpenAI, Claude, Ollama/open source models, and enterprise gateways.
Public or shared LLMDetails may be selectable by users without exposing decrypted model keys. Decryption should happen only server-side under an authorized system/user execution path. Valor prompts should reference model capability and purpose, not secrets.
Prompt Context
Valor workflow prompts should include:
- the user's persona mode and preferred complexity
- RBAC-visible objects and allowed operations
- available ExecModules and config schemas
- IntegrationAccount capabilities
- LLMDetails labels and model capability metadata
- relevant GrayMatter memory
- target surface: workflow, app generation, data workbook, MCP, deployment, or ValorIDE handoff
Code Anchors
- SageChat components:
src/components/SageChat,src/components/SageChatDock - Workflow command prompt:
src/components/SageChat/valorCommandPrompt.ts - Command protocol:
src/components/SageChat/workflowCommandProtocol.ts - Workflow context injection:
src/services/llmWorkflowContext.ts - Integration account console:
src/components/IntegrationAccountConsole