Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
11 changes: 6 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,17 @@ RUN npm run build

# --- Runtime Stage ---
FROM node:20-alpine AS runtime
RUN apk add --no-cache bash
RUN apk add --no-cache bash git
WORKDIR /app
ENV NODE_ENV=production

COPY package*.json ./

# Install production dependencies only
RUN npm ci --omit=dev --legacy-peer-deps

# Copy built application from the build stage
COPY --from=builder /app/dist ./dist

# Set the container's entrypoint
ENTRYPOINT ["node","dist/cli.js"]
ENV TERM=xterm-256color

ENTRYPOINT ["node", "dist/cli.js"]
CMD []
30 changes: 29 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -127,4 +127,32 @@ docker-image: ## Build the Docker image

docker-run: ## Run the application in a Docker container
@echo "Running Docker image: $(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_TAG) with args: $(DOCKER_CONTAINER_ARGS)"
@docker run --rm -it $(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_TAG) $(DOCKER_CONTAINER_ARGS)
@docker run --rm -it \
-v $(PWD):/workspace \
-w /workspace \
-e OPENAI_API_KEY \
-e ANTHROPIC_API_KEY \
-e GOOGLE_API_KEY \
$(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_TAG) $(DOCKER_CONTAINER_ARGS)

docker-run-local: ## Run with local config and workspace mounted
@echo "Running Docker with local config and workspace"
@docker run --rm -it \
-v $(PWD):/workspace \
-v $(HOME)/.config/binharic:/root/.config/binharic \
-w /workspace \
-e OPENAI_API_KEY \
-e ANTHROPIC_API_KEY \
-e GOOGLE_API_KEY \
$(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_TAG) $(DOCKER_CONTAINER_ARGS)

docker-shell: ## Open a shell in the Docker container for debugging
@echo "Opening shell in Docker container"
@docker run --rm -it \
-v $(PWD):/workspace \
-w /workspace \
-e OPENAI_API_KEY \
-e ANTHROPIC_API_KEY \
-e GOOGLE_API_KEY \
--entrypoint /bin/bash \
$(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_TAG)
26 changes: 22 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ like the ability to analyze projects, run tests, find bugs, and perform code rev
- Is fully customizable (like customizing system prompt)
- Comes with a built-in retrieval-augmented generation (RAG) pipeline
- Comes with a large set of built-in tools (like reading and writing files)
- Can use external tools via Model Context Protocol (MCP)
- Can use external tools via the Model Context Protocol (MCP)
- Comes with built-in workflows for standard software development tasks (like debugging and code review)

See the [ROADMAP.md](ROADMAP.md) for the list of implemented and planned features.
Expand All @@ -58,7 +58,7 @@ You can follow the instructions below to install and use Binharic in your termin
npm install -g @cogitator/binharic-cli
```

#### Usage
#### Running in the Terminal

```sh
# Make sure API keys are available in the environment
Expand All @@ -77,11 +77,29 @@ binharic
> So, it's recommended to use state-of-the-art models (like Claude Sonnet 4.5, GPT-5, and Gemini 2.5 Pro) for the best
> results.

#### Running in a Container

Alternatively, you can start Binharic in a container:

```sh
# API keys should be available in the environment already
docker run -it --rm \
-v $(PWD):/workspace \
-w /workspace \
-e OPENAI_API_KEY \
-e ANTHROPIC_API_KEY \
-e GOOGLE_API_KEY \
ghcr.io/cogitatortech/binharic-cli:<version>
```

`<version>` should be replaced with the version of the Binharic (like `0.1.0-alpha.4`) or `latest`.
Use `latest` if you want to use the latest (development) version of Binharic.

---

#### Documentation
### Documentation

See the [docs](docs) for more information on how to use Binharic coding agent.
See the [docs](docs) for more information on how to use the Binharic coding agent.

---

Expand Down
4 changes: 2 additions & 2 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ It includes planned features, improvements, and their current implementation sta
- [x] File search with @ mention
- [x] Non-blocking UI during LLM responses
- [x] Command syntax highlighting (partial match in yellow, full match in cyan)
- [x] Colored help menu items**
- [x] Colored help menu items\*\*
- [x] Clean message display (no "Binharic:" prefix)
- [x] Dynamic username from system (not hardcoded)
- [x] Tool results hidden from UI (only failures shown)
Expand Down Expand Up @@ -250,7 +250,7 @@ It includes planned features, improvements, and their current implementation sta
- [x] Multi-step tool execution with automatic loop control
- [x] Specialized agents with distinct personalities
- [ ] onStepFinish callbacks for monitoring
- [ ] prepareStep callbacks for dynamic configuration**
- [ ] prepareStep callbacks for dynamic configuration\*\*
- [ ] Multiple stopping conditions (step count, budget, errors, validation, completion)
- [ ] Goal-oriented planning
- [ ] Task decomposition
Expand Down
76 changes: 38 additions & 38 deletions docs/assets/diagrams/agentic_workflow.dot
Original file line number Diff line number Diff line change
@@ -1,65 +1,65 @@
digraph AgenticWorkflow {
// --- Graph Settings (Updated Style) ---
graph [
rankdir=LR,
label="AI Agentic Workflow",
fontsize=22,
fontname="Helvetica-Bold,Arial-Bold,sans-serif",
fontcolor="#333333",
labelloc=t,
compound=true,
bgcolor="#F8F9FA",
splines=ortho,
nodesep=0.6,
ranksep=1.2
rankdir = LR,
label = "AI Agentic Workflow",
fontsize = 22,
fontname = "Helvetica-Bold,Arial-Bold,sans-serif",
fontcolor = "#333333",
labelloc = t,
compound = true,
bgcolor = "#F8F9FA",
splines = ortho,
nodesep = 0.6,
ranksep = 1.2
];

// --- Default Node & Edge Styles (from example) ---
node [
fontname="Helvetica,Arial,sans-serif",
shape=box,
style="filled,rounded",
color="lightblue", // Border color
fillcolor="white", // Default fill color
penwidth=2
fontname = "Helvetica,Arial,sans-serif",
shape = box,
style = "filled,rounded",
color = "lightblue", // Border color
fillcolor = "white", // Default fill color
penwidth = 2
];
edge [
fontname="Helvetica,Arial,sans-serif",
color="black",
arrowhead=vee,
fontsize=10
fontname = "Helvetica,Arial,sans-serif",
color = "black",
arrowhead = vee,
fontsize = 10
];

// --- Node Definitions (with new colors) ---
Start [
shape=circle,
label="Start",
fontname="Helvetica-Bold,Arial-Bold,sans-serif"
shape = circle,
label = "Start",
fontname = "Helvetica-Bold,Arial-Bold,sans-serif"
];
End [
shape=doublecircle,
label="End",
fontname="Helvetica-Bold,Arial-Bold,sans-serif"
shape = doublecircle,
label = "End",
fontname = "Helvetica-Bold,Arial-Bold,sans-serif"
];

HumanLoop [
label="User Feedback",
fillcolor="lightgreen"
label = "User Feedback",
fillcolor = "lightgreen"
];
AIModel [
label="AI Model",
fillcolor="lightpink"
label = "AI Model",
fillcolor = "lightpink"
];

// --- Agentic Loop Cluster (styled like example) ---
subgraph cluster_agentic_loop {
label = "Agentic Loop";
style = "dashed";
color = "lightgrey";
fontname="Helvetica-Bold,Arial-Bold,sans-serif";
fontname = "Helvetica-Bold,Arial-Bold,sans-serif";

// Nodes inside the cluster get a yellow fill
node [fillcolor="lightyellow"];
node [fillcolor = "lightyellow"];

Plan;
Execute;
Expand All @@ -69,11 +69,11 @@ Plan -> Execute -> Check;
}

// --- Layout and Workflow Connections ---
HumanLoop -> Execute -> AIModel [style=invis, minlen=1];
HumanLoop -> Execute -> AIModel [style = invis, minlen = 1];

Start -> Plan [lhead=cluster_agentic_loop];
Check -> End [ltail=cluster_agentic_loop];
Start -> Plan [lhead = cluster_agentic_loop];
Check -> End [ltail = cluster_agentic_loop];

HumanLoop -> Plan [lhead=cluster_agentic_loop, constraint=false, xlabel=" Feedback "];
Execute -> AIModel [ltail=cluster_agentic_loop, constraint=false, xlabel="Uses "];
HumanLoop -> Plan [lhead = cluster_agentic_loop, constraint = false, xlabel = " Feedback "];
Execute -> AIModel [ltail = cluster_agentic_loop, constraint = false, xlabel = "Uses "];
}
Loading
Loading