@poncho-ai/harness 0.31.2 → 0.32.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +5 -5
- package/.turbo/turbo-lint.log +6 -0
- package/.turbo/turbo-test.log +34 -0
- package/CHANGELOG.md +14 -0
- package/dist/index.d.ts +37 -1
- package/dist/index.js +502 -90
- package/package.json +1 -1
- package/src/config.ts +6 -0
- package/src/harness.ts +34 -9
- package/src/index.ts +2 -0
- package/src/reminder-store.ts +334 -0
- package/src/reminder-tools.ts +168 -0
- package/test/reminder-store.test.ts +159 -0
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @poncho-ai/harness@0.
|
|
2
|
+
> @poncho-ai/harness@0.32.0 build /Users/cesar/Dev/latitude/poncho-ai/packages/harness
|
|
3
3
|
> node scripts/embed-docs.js && tsup src/index.ts --format esm --dts
|
|
4
4
|
|
|
5
5
|
[embed-docs] Generated poncho-docs.ts with 4 topics
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
[34mCLI[39m tsup v8.5.1
|
|
9
9
|
[34mCLI[39m Target: es2022
|
|
10
10
|
[34mESM[39m Build start
|
|
11
|
-
[32mESM[39m [1mdist/index.js [22m[
|
|
12
|
-
[32mESM[39m ⚡️ Build success in
|
|
11
|
+
[32mESM[39m [1mdist/index.js [22m[32m340.95 KB[39m
|
|
12
|
+
[32mESM[39m ⚡️ Build success in 194ms
|
|
13
13
|
[34mDTS[39m Build start
|
|
14
|
-
[32mDTS[39m ⚡️ Build success in
|
|
15
|
-
[32mDTS[39m [1mdist/index.d.ts [22m[
|
|
14
|
+
[32mDTS[39m ⚡️ Build success in 3547ms
|
|
15
|
+
[32mDTS[39m [1mdist/index.d.ts [22m[32m34.66 KB[39m
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
|
|
2
|
+
> @poncho-ai/harness@0.26.0 test /Users/cesar/Dev/latitude/poncho-ai/packages/harness
|
|
3
|
+
> vitest
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
[7m[1m[36m RUN [39m[22m[27m [36mv1.6.1[39m [90m/Users/cesar/Dev/latitude/poncho-ai/packages/harness[39m
|
|
7
|
+
|
|
8
|
+
[90mstdout[2m | test/mcp.test.ts[2m > [22m[2mmcp bridge protocol transports[2m > [22m[2mdiscovers and calls tools over streamable HTTP[22m[39m
|
|
9
|
+
[poncho][mcp] {"event":"catalog.loaded","server":"remote","discoveredCount":1}
|
|
10
|
+
[poncho][mcp] {"event":"tools.selected","requestedPatternCount":1,"registeredCount":1,"filteredByPolicyCount":0,"filteredByIntentCount":0}
|
|
11
|
+
|
|
12
|
+
[90mstdout[2m | test/mcp.test.ts[2m > [22m[2mmcp bridge protocol transports[2m > [22m[2msends custom headers alongside bearer token[22m[39m
|
|
13
|
+
[poncho][mcp] {"event":"catalog.loaded","server":"custom-headers","discoveredCount":1}
|
|
14
|
+
|
|
15
|
+
[90mstderr[2m | test/mcp.test.ts[2m > [22m[2mmcp bridge protocol transports[2m > [22m[2mskips discovery when bearer token env value is missing[22m[39m
|
|
16
|
+
[90mstdout[2m | test/mcp.test.ts[2m > [22m[2mmcp bridge protocol transports[2m > [22m[2mselects discovered tools by requested patterns[22m[39m
|
|
17
|
+
[poncho][mcp] {"event":"auth.token_missing","server":"remote","tokenEnv":"MISSING_TOKEN_ENV"}
|
|
18
|
+
[poncho][mcp] {"event":"catalog.loaded","server":"remote","discoveredCount":2}
|
|
19
|
+
[poncho][mcp] {"event":"tools.selected","requestedPatternCount":1,"registeredCount":1,"filteredByPolicyCount":0,"filteredByIntentCount":1}
|
|
20
|
+
|
|
21
|
+
[poncho][mcp] {"event":"tools.selected","requestedPatternCount":1,"registeredCount":2,"filteredByPolicyCount":0,"filteredByIntentCount":0}
|
|
22
|
+
|
|
23
|
+
[90mstdout[2m | test/mcp.test.ts[2m > [22m[2mmcp bridge protocol transports[2m > [22m[2mskips discovery when bearer token env value is missing[22m[39m
|
|
24
|
+
[poncho][mcp] {"event":"tools.selected","requestedPatternCount":1,"registeredCount":0,"filteredByPolicyCount":0,"filteredByIntentCount":0}
|
|
25
|
+
|
|
26
|
+
[event] step:completed {"type":"step:completed","step":1,"duration":1}
|
|
27
|
+
[32m✓[39m test/telemetry.test.ts [2m ([22m[2m3 tests[22m[2m)[22m[90m 5[2mms[22m[39m
|
|
28
|
+
[event] step:started {"type":"step:started","step":2}
|
|
29
|
+
[32m✓[39m test/schema-converter.test.ts [2m ([22m[2m27 tests[22m[2m)[22m[90m 13[2mms[22m[39m
|
|
30
|
+
[90mstdout[2m | test/mcp.test.ts[2m > [22m[2mmcp bridge protocol transports[2m > [22m[2mreturns actionable errors for 403 permission failures[22m[39m
|
|
31
|
+
[poncho][mcp] {"event":"catalog.loaded","server":"remote","discoveredCount":1}
|
|
32
|
+
[poncho][mcp] {"event":"tools.selected","requestedPatternCount":1,"registeredCount":1,"filteredByPolicyCount":0,"filteredByIntentCount":0}
|
|
33
|
+
|
|
34
|
+
[32m✓[39m test/mcp.test.ts [2m ([22m[2m7 tests[22m[2m)[22m[90m 84[2mms[22m[39m
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @poncho-ai/harness
|
|
2
2
|
|
|
3
|
+
## 0.32.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#68](https://github.com/cesr/poncho-ai/pull/68) [`5a7e370`](https://github.com/cesr/poncho-ai/commit/5a7e3700a5ee441ef41cf4dc0ca70ff90e57d282) Thanks [@cesr](https://github.com/cesr)! - Add one-off reminders: agents can dynamically set, list, and cancel reminders that fire at a specific time. Fired reminders are immediately deleted from storage. Includes polling for local dev and Vercel cron integration.
|
|
8
|
+
|
|
9
|
+
## 0.31.3
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#56](https://github.com/cesr/poncho-ai/pull/56) [`28b2913`](https://github.com/cesr/poncho-ai/commit/28b291379e640dec53a66c41a2795d0a9fbb9ee7) Thanks [@cesr](https://github.com/cesr)! - Fix historical tool result truncation reliability for deployed conversations.
|
|
14
|
+
|
|
15
|
+
This stamps `runId` on all harness-authored assistant messages and adds a fallback truncation boundary for legacy histories that lack `runId` metadata.
|
|
16
|
+
|
|
3
17
|
## 0.31.2
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
package/dist/index.d.ts
CHANGED
|
@@ -461,6 +461,12 @@ interface PonchoConfig extends McpConfig {
|
|
|
461
461
|
lambda?: Record<string, unknown>;
|
|
462
462
|
fly?: Record<string, unknown>;
|
|
463
463
|
};
|
|
464
|
+
/** One-off reminders. When enabled, the agent gets set_reminder / list_reminders / cancel_reminder tools. */
|
|
465
|
+
reminders?: {
|
|
466
|
+
enabled?: boolean;
|
|
467
|
+
/** Cron expression controlling how often the reminder poll runs (local and serverless). Default: every 10 minutes. */
|
|
468
|
+
pollSchedule?: string;
|
|
469
|
+
};
|
|
464
470
|
/** Set to `false` to disable the built-in web UI (headless / API-only mode). */
|
|
465
471
|
webUi?: false;
|
|
466
472
|
/** Enable browser automation tools. Set `true` for defaults, or provide config. */
|
|
@@ -551,6 +557,33 @@ interface TodoItem {
|
|
|
551
557
|
updatedAt: number;
|
|
552
558
|
}
|
|
553
559
|
|
|
560
|
+
type ReminderStatus = "pending" | "fired" | "cancelled";
|
|
561
|
+
interface Reminder {
|
|
562
|
+
id: string;
|
|
563
|
+
task: string;
|
|
564
|
+
scheduledAt: number;
|
|
565
|
+
timezone?: string;
|
|
566
|
+
status: ReminderStatus;
|
|
567
|
+
createdAt: number;
|
|
568
|
+
conversationId: string;
|
|
569
|
+
ownerId?: string;
|
|
570
|
+
}
|
|
571
|
+
interface ReminderStore {
|
|
572
|
+
list(): Promise<Reminder[]>;
|
|
573
|
+
create(input: {
|
|
574
|
+
task: string;
|
|
575
|
+
scheduledAt: number;
|
|
576
|
+
timezone?: string;
|
|
577
|
+
conversationId: string;
|
|
578
|
+
ownerId?: string;
|
|
579
|
+
}): Promise<Reminder>;
|
|
580
|
+
cancel(id: string): Promise<Reminder>;
|
|
581
|
+
delete(id: string): Promise<void>;
|
|
582
|
+
}
|
|
583
|
+
declare const createReminderStore: (agentId: string, config?: StateConfig, options?: {
|
|
584
|
+
workingDir?: string;
|
|
585
|
+
}) => ReminderStore;
|
|
586
|
+
|
|
554
587
|
declare const OPENAI_CODEX_CLIENT_ID = "app_EMoamEEZ73f0CkXaXp7hrann";
|
|
555
588
|
interface OpenAICodexAuthConfig {
|
|
556
589
|
refreshTokenEnv?: string;
|
|
@@ -688,6 +721,7 @@ declare class AgentHarness {
|
|
|
688
721
|
private skillContextWindow;
|
|
689
722
|
private memoryStore?;
|
|
690
723
|
private todoStore?;
|
|
724
|
+
reminderStore?: ReminderStore;
|
|
691
725
|
private loadedConfig?;
|
|
692
726
|
private loadedSkills;
|
|
693
727
|
private skillFingerprint;
|
|
@@ -886,6 +920,8 @@ declare const createSkillTools: (skills: SkillMetadata[], options?: {
|
|
|
886
920
|
}) => ToolDefinition[];
|
|
887
921
|
declare const normalizeScriptPolicyPath: (relativePath: string) => string;
|
|
888
922
|
|
|
923
|
+
declare const createReminderTools: (store: ReminderStore) => ToolDefinition[];
|
|
924
|
+
|
|
889
925
|
interface OtlpConfig {
|
|
890
926
|
url: string;
|
|
891
927
|
headers?: Record<string, string>;
|
|
@@ -912,4 +948,4 @@ declare class TelemetryEmitter {
|
|
|
912
948
|
|
|
913
949
|
declare const createSubagentTools: (manager: SubagentManager) => ToolDefinition[];
|
|
914
950
|
|
|
915
|
-
export { type AgentFrontmatter, AgentHarness, type AgentIdentity, type AgentLimitsConfig, type AgentModelConfig, type ArchivedToolResult$1 as ArchivedToolResult, type BuiltInToolToggles, type CompactMessagesOptions, type CompactResult, type CompactionConfig, type Conversation, type ConversationState, type ConversationStore, type ConversationSummary, type CronJobConfig, type HarnessOptions, type HarnessRunOutput, InMemoryConversationStore, InMemoryStateStore, LatitudeCapture, type LatitudeCaptureConfig, LocalMcpBridge, LocalUploadStore, type MainMemory, type McpConfig, type MemoryConfig, type MemoryStore, type MessagingChannelConfig, type ModelProviderFactory, OPENAI_CODEX_CLIENT_ID, type OpenAICodexAuthConfig, type OpenAICodexDeviceAuthRequest, type OpenAICodexSession, type OtlpConfig, type OtlpOption, PONCHO_UPLOAD_SCHEME, type ParsedAgent, type PendingSubagentResult, type PonchoConfig, type ProviderConfig, type RemoteMcpServerConfig, type RuntimeRenderContext, S3UploadStore, STORAGE_SCHEMA_VERSION, type SkillContextEntry, type SkillMetadata, type StateConfig, type StateProviderName, type StateStore, type StorageConfig, type SubagentManager, type SubagentResult, type SubagentSpawnResult, type SubagentSummary, type TelemetryConfig, TelemetryEmitter, type ToolAccess, type ToolCall, ToolDispatcher, type ToolExecutionResult, type UploadStore, type UploadsConfig, VercelBlobUploadStore, buildAgentDirectoryName, buildSkillContextWindow, compactMessages, completeOpenAICodexDeviceAuth, createConversationStore, createDefaultTools, createDeleteDirectoryTool, createDeleteTool, createEditTool, createMemoryStore, createMemoryTools, createModelProvider, createSearchTools, createSkillTools, createStateStore, createSubagentTools, createUploadStore, createWriteTool, deleteOpenAICodexSession, deriveUploadKey, ensureAgentIdentity, estimateTokens, estimateTotalTokens, findSafeSplitPoint, generateAgentId, getAgentStoreDirectory, getModelContextWindow, getOpenAICodexAccessToken, getOpenAICodexAuthFilePath, getOpenAICodexRequiredScopes, getPonchoStoreRoot, jsonSchemaToZod, loadPonchoConfig, loadSkillContext, loadSkillInstructions, loadSkillMetadata, normalizeOtlp, normalizeScriptPolicyPath, parseAgentFile, parseAgentMarkdown, ponchoDocsTool, readOpenAICodexSession, readSkillResource, renderAgentPrompt, resolveAgentIdentity, resolveCompactionConfig, resolveMemoryConfig, resolveSkillDirs, resolveStateConfig, slugifyStorageComponent, startOpenAICodexDeviceAuth, writeOpenAICodexSession };
|
|
951
|
+
export { type AgentFrontmatter, AgentHarness, type AgentIdentity, type AgentLimitsConfig, type AgentModelConfig, type ArchivedToolResult$1 as ArchivedToolResult, type BuiltInToolToggles, type CompactMessagesOptions, type CompactResult, type CompactionConfig, type Conversation, type ConversationState, type ConversationStore, type ConversationSummary, type CronJobConfig, type HarnessOptions, type HarnessRunOutput, InMemoryConversationStore, InMemoryStateStore, LatitudeCapture, type LatitudeCaptureConfig, LocalMcpBridge, LocalUploadStore, type MainMemory, type McpConfig, type MemoryConfig, type MemoryStore, type MessagingChannelConfig, type ModelProviderFactory, OPENAI_CODEX_CLIENT_ID, type OpenAICodexAuthConfig, type OpenAICodexDeviceAuthRequest, type OpenAICodexSession, type OtlpConfig, type OtlpOption, PONCHO_UPLOAD_SCHEME, type ParsedAgent, type PendingSubagentResult, type PonchoConfig, type ProviderConfig, type Reminder, type ReminderStatus, type ReminderStore, type RemoteMcpServerConfig, type RuntimeRenderContext, S3UploadStore, STORAGE_SCHEMA_VERSION, type SkillContextEntry, type SkillMetadata, type StateConfig, type StateProviderName, type StateStore, type StorageConfig, type SubagentManager, type SubagentResult, type SubagentSpawnResult, type SubagentSummary, type TelemetryConfig, TelemetryEmitter, type ToolAccess, type ToolCall, ToolDispatcher, type ToolExecutionResult, type UploadStore, type UploadsConfig, VercelBlobUploadStore, buildAgentDirectoryName, buildSkillContextWindow, compactMessages, completeOpenAICodexDeviceAuth, createConversationStore, createDefaultTools, createDeleteDirectoryTool, createDeleteTool, createEditTool, createMemoryStore, createMemoryTools, createModelProvider, createReminderStore, createReminderTools, createSearchTools, createSkillTools, createStateStore, createSubagentTools, createUploadStore, createWriteTool, deleteOpenAICodexSession, deriveUploadKey, ensureAgentIdentity, estimateTokens, estimateTotalTokens, findSafeSplitPoint, generateAgentId, getAgentStoreDirectory, getModelContextWindow, getOpenAICodexAccessToken, getOpenAICodexAuthFilePath, getOpenAICodexRequiredScopes, getPonchoStoreRoot, jsonSchemaToZod, loadPonchoConfig, loadSkillContext, loadSkillInstructions, loadSkillMetadata, normalizeOtlp, normalizeScriptPolicyPath, parseAgentFile, parseAgentMarkdown, ponchoDocsTool, readOpenAICodexSession, readSkillResource, renderAgentPrompt, resolveAgentIdentity, resolveCompactionConfig, resolveMemoryConfig, resolveSkillDirs, resolveStateConfig, slugifyStorageComponent, startOpenAICodexDeviceAuth, writeOpenAICodexSession };
|