Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
039c9cd
fix(context-injector): use camelCase filePath property name
vtemian Jan 16, 2026
cdc3c05
fix(pty): add error handling for spawn failures
vtemian Jan 16, 2026
ff904f7
feat(utils): add errors.ts utility for unified error handling
vtemian Jan 16, 2026
baca78c
feat(utils): add logger.ts utility for standardized logging
vtemian Jan 16, 2026
de37ae5
feat(utils): add centralized config utility
vtemian Jan 16, 2026
91fc9e7
fix: validate model configuration and fallback to defaults
vtemian Jan 16, 2026
ed94785
refactor: use centralized config, logger, and error utilities
vtemian Jan 16, 2026
05f2ad6
docs: add milestone artifact indexing design
vtemian Jan 16, 2026
649caa8
docs(design): clarify milestone artifact classification
vtemian Jan 16, 2026
16207f4
feat(indexing): add milestone artifact search tool
vtemian Jan 16, 2026
4db82b6
feat(octto): add browser-based brainstorming system
vtemian Jan 16, 2026
589263f
feat(indexing): add milestone artifact indexing
vtemian Jan 17, 2026
81ebd4a
fix(agents): reduce confirmation prompts
vtemian Jan 17, 2026
1e29646
fix(config): validate model overrides against opencode.json
vtemian Jan 17, 2026
06e113e
feat(task): update logger test to use ESM import
vtemian Jan 17, 2026
c23e720
fix(brainstormer): make agent decisive instead of question-seeking
vtemian Jan 17, 2026
ddc6f03
feat(octto): expand question schema support
vtemian Jan 17, 2026
f1718e0
fix(octto): address review feedback
vtemian Jan 17, 2026
fd73d1d
fix(config): clean up model validation tests
vtemian Jan 17, 2026
976875e
fix(config): relax model validation
vtemian Jan 18, 2026
5d56e0f
test(config): cover model validation
vtemian Jan 18, 2026
ec46a3a
test(config): clean lint warnings
vtemian Jan 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions biome.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,7 @@
"organizeImports": {
"level": "on",
"options": {
"groups": [
[":BUN:", ":NODE:"],
":BLANK_LINE:",
[":PACKAGE:"],
":BLANK_LINE:",
":PATH:"
]
"groups": [[":BUN:", ":NODE:"], ":BLANK_LINE:", [":PACKAGE:"], ":BLANK_LINE:", ":PATH:"]
}
}
}
Expand Down
32 changes: 29 additions & 3 deletions bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,18 @@
"name": "micode",
"version": "0.8.4",
"description": "OpenCode plugin with Brainstorm-Research-Plan-Implement workflow",
"module": "src/index.ts",
"main": "src/index.ts",
"module": "dist/index.js",
"main": "dist/index.js",
"types": "src/index.ts",
"type": "module",
"files": [
"src",
"dist",
"INSTALL_CLAUDE.md"
],
"scripts": {
"prepare": "lefthook install",
"build": "tsc --noEmit",
"build": "bun build src/index.ts --outdir dist --target bun",
"typecheck": "tsc --noEmit",
"prepublishOnly": "bun run typecheck",
"test": "bun test",
Expand All @@ -39,7 +40,7 @@
"url": "https://github.com/vtemian/micode/issues"
},
"dependencies": {
"@opencode-ai/plugin": "1.1.6",
"@opencode-ai/plugin": "1.1.23",
"bun-pty": "^0.4.5",
"valibot": "^1.2.0"
},
Expand Down
1 change: 0 additions & 1 deletion src/agents/artifact-searcher.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import type { AgentConfig } from "@opencode-ai/sdk";
export const artifactSearcherAgent: AgentConfig = {
description: "Searches past handoffs, plans, and ledgers for relevant precedent",
mode: "subagent",
model: "openai/gpt-5.2-codex",
temperature: 0.3,
tools: {
edit: false,
Expand Down
164 changes: 164 additions & 0 deletions src/agents/bootstrapper.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
// src/agents/bootstrapper.ts
import type { AgentConfig } from "@opencode-ai/sdk";

export const bootstrapperAgent: AgentConfig = {
description: "Analyzes a request and creates exploration branches with scopes for octto brainstorming",
mode: "subagent",
temperature: 0.5,
prompt: `<purpose>
Analyze the user's request and create 2-4 exploration branches.
Each branch explores ONE specific aspect of the design.
</purpose>

<output-format>
Return ONLY a JSON object. No markdown, no explanation.

{
"branches": [
{
"id": "unique_snake_case_id",
"scope": "One sentence describing what this branch explores",
"initial_question": {
"type": "<any question type from list below>",
"config": { ... }
}
}
]
}
</output-format>

<branch-guidelines>
<guideline>Each branch explores ONE distinct aspect (not overlapping)</guideline>
<guideline>Scope is a clear boundary - questions stay within scope</guideline>
<guideline>2-4 branches total - don't over-decompose</guideline>
<guideline>Branch IDs are short snake_case identifiers</guideline>
</branch-guidelines>

<example>
Request: "Add healthcheck endpoints to the API"

{
"branches": [
{
"id": "services",
"scope": "Which services and dependencies need health monitoring",
"initial_question": {
"type": "pick_many",
"config": {
"question": "Which services should the healthcheck monitor?",
"options": [
{"id": "db", "label": "Database (PostgreSQL)"},
{"id": "cache", "label": "Cache (Redis)"},
{"id": "queue", "label": "Message Queue"},
{"id": "external", "label": "External APIs"}
]
}
}
},
{
"id": "response_format",
"scope": "What information the healthcheck endpoint returns",
"initial_question": {
"type": "pick_one",
"config": {
"question": "What level of detail should the healthcheck return?",
"options": [
{"id": "simple", "label": "Simple (just OK/ERROR)"},
{"id": "detailed", "label": "Detailed (status per service)"},
{"id": "full", "label": "Full (status + metrics + version)"}
]
}
}
},
{
"id": "security",
"scope": "Authentication and access control for healthcheck",
"initial_question": {
"type": "pick_one",
"config": {
"question": "Should the healthcheck endpoint require authentication?",
"options": [
{"id": "public", "label": "Public (no auth)"},
{"id": "internal", "label": "Internal only (IP whitelist)"},
{"id": "authenticated", "label": "Requires API key"}
]
}
}
}
]
}
</example>

<question-types>
<type name="pick_one">
Single choice. config: { question, options: [{id, label, description?}], recommended?, context? }
</type>

<type name="pick_many">
Multiple choice. config: { question, options: [{id, label, description?}], recommended?: string[], min?, max?, context? }
</type>

<type name="confirm">
Yes/no. config: { question, context?, yesLabel?, noLabel?, allowCancel? }
</type>

<type name="ask_text">
Free text. config: { question, placeholder?, context?, multiline? }
</type>

<type name="slider">
Numeric range. config: { question, min, max, step?, defaultValue?, context? }
</type>

<type name="rank">
Order items. config: { question, options: [{id, label, description?}], context? }
</type>

<type name="rate">
Rate items (stars). config: { question, options: [{id, label, description?}], min?, max?, context? }
</type>

<type name="thumbs">
Thumbs up/down. config: { question, context? }
</type>

<type name="show_options">
Options with pros/cons. config: { question, options: [{id, label, description?, pros?: string[], cons?: string[]}], recommended?, allowFeedback?, context? }
</type>

<type name="show_diff">
Code diff review. config: { question, before, after, filePath?, language? }
</type>

<type name="ask_code">
Code input. config: { question, language?, placeholder?, context? }
</type>

<type name="ask_image">
Image upload. config: { question, multiple?, maxImages?, context? }
</type>

<type name="ask_file">
File upload. config: { question, multiple?, maxFiles?, accept?: string[], context? }
</type>

<type name="emoji_react">
Emoji selection. config: { question, emojis?: string[], context? }
</type>

<type name="review_section">
Section review. config: { question, content, context? }
</type>

<type name="show_plan">
Plan review. config: { question, sections: [{id, title, content}] }
</type>
</question-types>

<never-do>
<forbidden>Never create more than 4 branches</forbidden>
<forbidden>Never create overlapping scopes</forbidden>
<forbidden>Never wrap output in markdown code blocks</forbidden>
<forbidden>Never include text outside the JSON</forbidden>
</never-do>`,
};
Loading