Skip to content

Task template arguments#403

Merged
s-kostyaev merged 10 commits intomainfrom
task-template-arguments
Apr 29, 2026
Merged

Task template arguments#403
s-kostyaev merged 10 commits intomainfrom
task-template-arguments

Conversation

@s-kostyaev
Copy link
Copy Markdown
Owner

No description provided.

Extend the task tool to render prompt templates from relative template paths with object-based substitution, strict path checks, validation hints, and callback-based errors. Add tests for rendering, validation feedback, and path traversal rejection.
Add an option to display session buffers whenever session-backed generation starts. Stream task subagents into their worker session buffers so enabling the option reveals subagent sessions with their output, and cover the behavior with tests.
Insert task prompts into worker session buffers as Main agent turns before streaming subagent responses. Preserve existing worker session metadata when adding task state and stream responses after the inserted assistant header.
Capture the worker session, buffer, tools, and system prompt in task loop callbacks so subagent continuations do not depend on the provider callback buffer after tool calls. Store the subagent system prompt in session extra and add regression coverage for continuing from a buffer with no current session.
Document task tool prompt templates, template path resolution, argument validation hints, subagent continuation behavior, and session buffer display. Regenerate the Info manual from README.org.
Normalize stored tool-use arguments before sending chat prompts so OpenAI-compatible providers can serialize retried tool-call history with raw UTF-8 or JSON-string arguments. Add regression tests for unibyte JSON arguments and malformed JSON fallback.
Decode unibyte strings in provider chat request data before request serialization so OpenAI-compatible tool-call arguments generated by older or mixed llm versions remain JSON serializable. Add a regression test for unibyte function argument strings.
Use locate-user-emacs-file for the task template directory default to satisfy package-lint. Make the provider request sanitization regression construct an explicit unibyte string so it passes across Emacs versions with different json-serialize string representations.
Collect streaming tool calls using the maximum emitted tool-call index so multi-call batches no longer write past the collector vector. Add a regression test covering multiple OpenAI-compatible tool calls in one streaming chunk.
@s-kostyaev s-kostyaev merged commit 8685e71 into main Apr 29, 2026
14 checks passed
@s-kostyaev s-kostyaev deleted the task-template-arguments branch April 29, 2026 00:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant