diff --git a/CHANGELOG.md b/CHANGELOG.md index c5b7a7a..b9ee3e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,19 @@ +# [0.10.0](https://github.com/drivecore/mycoder/compare/v0.9.0...v0.10.0) (2025-03-11) + + +### Bug Fixes + +* add deepmerge to cli package.json ([ab66377](https://github.com/drivecore/mycoder/commit/ab66377342c9f23fa874d2776e73d365141e8801)) +* update hierarchical configuration system to fix failing tests ([93d949c](https://github.com/drivecore/mycoder/commit/93d949c03b7ebe96bad36713f6476c38d2a35224)) + + +### Features + +* add back token tracking, system prompt caching. ([ddc04ab](https://github.com/drivecore/mycoder/commit/ddc04ab0778eb2f571897e825c8d8ba17651db09)) +* add showStdIn and showStdout options to shellMessage and shellStart ([aed1b9f](https://github.com/drivecore/mycoder/commit/aed1b9f6ba489da19f2170c136861a7c80ad6e33)), closes [#167](https://github.com/drivecore/mycoder/issues/167) +* add token caching. issue 145 ([d78723b](https://github.com/drivecore/mycoder/commit/d78723bb6d0514110088caf7009e196e3f79769e)) +* implement hierarchical configuration system ([84d73d1](https://github.com/drivecore/mycoder/commit/84d73d1e6324670890a203f455fe257aeb6ed07a)), closes [#153](https://github.com/drivecore/mycoder/issues/153) + # [0.9.0](https://github.com/drivecore/mycoder/compare/v0.8.0...v0.9.0) (2025-03-11) diff --git a/package.json b/package.json index 776f352..5f219dd 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "mycoder-monorepo", - "version": "0.9.0", + "version": "0.10.0", "type": "module", "private": true, "packageManager": "pnpm@10.2.1", diff --git a/packages/agent/package.json b/packages/agent/package.json index 7bb5c9e..3422fd3 100644 --- a/packages/agent/package.json +++ b/packages/agent/package.json @@ -1,6 +1,6 @@ { "name": "mycoder-agent", - "version": "0.9.0", + "version": "0.10.0", "description": "Agent module for mycoder - an AI-powered software development assistant", "type": "module", "main": "dist/index.js", diff --git a/packages/agent/src/core/llm/providers/anthropic.ts b/packages/agent/src/core/llm/providers/anthropic.ts index 835fac7..718b51c 100644 --- a/packages/agent/src/core/llm/providers/anthropic.ts +++ b/packages/agent/src/core/llm/providers/anthropic.ts @@ -57,13 +57,16 @@ function addCacheControlToMessages( if (typeof m.content === 'string') { return { ...m, - content: [ - { - type: 'text', - text: m.content, - cache_control: { type: 'ephemeral' }, - }, - ], + content: + i >= messages.length - 2 + ? [ + { + type: 'text', + text: m.content, + cache_control: { type: 'ephemeral' }, + }, + ] + : m.content, }; } return { diff --git a/packages/agent/src/core/toolAgent/config.ts b/packages/agent/src/core/toolAgent/config.ts index 3ae76a8..29737c9 100644 --- a/packages/agent/src/core/toolAgent/config.ts +++ b/packages/agent/src/core/toolAgent/config.ts @@ -144,15 +144,15 @@ export function getDefaultSystemPrompt(toolContext: ToolContext): string { '', '## GitHub Mode', 'GitHub mode is enabled. You should work with GitHub issues and PRs as part of your workflow:', - '- Start from existing GitHub issues or create new ones for tasks', + '- Start from existing GitHub issues (gh issue view 21) or create new ones (gh issue create) for tasks', "- Create branches for issues you're working on", '- Make commits with descriptive messages', - '- Create PRs when work is complete', + '- Create PRs when work is complete (gh pr create)', '- Create additional GitHub issues for follow-up tasks or ideas', '', - 'You can use the GitHub CLI (`gh`) for all GitHub interactions.', + 'You should use the Github CLI tool, gh, and the git cli tool, git, that you can access via shell commands.', '', - 'When creating GitHub issues, PRs, or comments, use temporary markdown files for the content instead of inline text:', + 'When creating GitHub issues, PRs, or comments, via the gh cli tool, use temporary markdown files for the content instead of inline text:', '- Create a temporary markdown file with the content you want to include', '- Use the file with GitHub CLI commands (e.g., `gh issue create --body-file temp.md`)', '- Clean up the temporary file when done', diff --git a/packages/agent/src/tools/system/shellMessage.ts b/packages/agent/src/tools/system/shellMessage.ts index 77479d6..49f3f7c 100644 --- a/packages/agent/src/tools/system/shellMessage.ts +++ b/packages/agent/src/tools/system/shellMessage.ts @@ -58,13 +58,13 @@ const parameterSchema = z.object({ .boolean() .optional() .describe( - 'Whether to show the input in the logs (default: false or value from shellStart)', + 'Whether to show the input to the user, or keep the output clean (default: false or value from shellStart)', ), showStdout: z .boolean() .optional() .describe( - 'Whether to show output in the logs (default: false or value from shellStart)', + 'Whether to show output to the user, or keep the output clean (default: false or value from shellStart)', ), }); diff --git a/packages/agent/src/tools/system/shellStart.ts b/packages/agent/src/tools/system/shellStart.ts index 8832ff4..231c50b 100644 --- a/packages/agent/src/tools/system/shellStart.ts +++ b/packages/agent/src/tools/system/shellStart.ts @@ -41,11 +41,15 @@ const parameterSchema = z.object({ showStdIn: z .boolean() .optional() - .describe('Whether to show the command input in the logs (default: false)'), + .describe( + 'Whether to show the command input to the user, or keep the output clean (default: false)', + ), showStdout: z .boolean() .optional() - .describe('Whether to show command output in the logs (default: false)'), + .describe( + 'Whether to show command output to the user, or keep the output clean (default: false)', + ), }); const returnSchema = z.union([ diff --git a/packages/cli/package.json b/packages/cli/package.json index 8da6b10..8f05bea 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,7 +1,7 @@ { "name": "mycoder", "description": "A command line tool using agent that can do arbitrary tasks, including coding tasks", - "version": "0.9.0", + "version": "0.10.0", "type": "module", "bin": "./bin/cli.js", "main": "./dist/index.js",