mirror of
https://github.com/Narcooo/inkos.git
synced 2026-08-28 23:02:03 +08:00
feat(core): wire transformContext into Agent for truth file injection
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -15,6 +15,7 @@ import {
|
||||
createLsTool,
|
||||
createWriteTruthFileTool,
|
||||
} from "./agent-tools.js";
|
||||
import { createBookContextTransform } from "./context-transform.js";
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Types
|
||||
@@ -245,6 +246,7 @@ export async function runAgentSession(
|
||||
createLsTool(projectRoot),
|
||||
],
|
||||
},
|
||||
transformContext: createBookContextTransform(bookId, projectRoot),
|
||||
streamFn: streamSimple,
|
||||
getApiKey: (provider: string) => {
|
||||
if (config.apiKey) return config.apiKey;
|
||||
|
||||
@@ -11,3 +11,4 @@ export {
|
||||
createLsTool,
|
||||
} from "./agent-tools.js";
|
||||
export { runAgentSession, evictAgentCache, type AgentSessionConfig, type AgentSessionResult } from "./agent-session.js";
|
||||
export { createBookContextTransform } from "./context-transform.js";
|
||||
|
||||
Reference in New Issue
Block a user