Phi-4 Mini 3.8B (Ollama) is a 2.5GB model with a 128K tokens (131,072) context and native function calling, priced Free (self-hosted). That last part is the point: most models this small cannot be trusted to emit a well-formed tool call, and Atlas is a tool-calling agent. Phi-4 Mini makes a genuinely capable small_model, handling subagents, titles, and summaries for free on almost any machine. What it cannot do is a multi-file refactor, because 3.8B of capacity is not enough.
Why does native function calling matter in a 3.8B model?
Phi-4 Mini 3.8B (Ollama) treats function calling as an advertised, trained capability rather than an emergent hope, which is rare below 7B and exactly what an agent runtime needs. Atlas is a tool-calling agent, so a small model that emits malformed calls is not slow, it is broken.
Most models at 3.8B fall over on tool schemas: they hallucinate argument names, drop required fields, or wrap the call in prose. Phi-4 Mini 3.8B was trained for the job. Inside Atlas that matters because every Atlas tool call is permission-gated against allow, ask, and deny rules before it runs, and a call that is not well-formed never even reaches the permission layer. Atlas connects to Model Context Protocol servers and exposes their tools to the agent, which increases the number of tool schemas a model must handle correctly. Phi-4 Mini 3.8B is the rare model that can route among them from a 2.5GB download.
How do you use Phi-4 Mini 3.8B as the Atlas small_model?
Set small_model to ollama/phi4-mini:3.8b so Atlas subagents, titles, and summaries all run on a free local model, while model stays on a larger coder tag. Phi-4 Mini 3.8B costs roughly 4.5GB to serve, so it sits resident alongside a much larger main model without evicting it.
Pull it with ollama pull phi4-mini:3.8b (2.5GB, aliased to :latest), then in atlas.json register phi4-mini:3.8b under the ollama provider with limit.context 131072 and limit.output 8192. Leave model on a larger coder tag and use /models to confirm both resolve. Atlas fans out work to subagents that can run in the foreground or in parallel background sessions, and those subagents are the biggest consumers of the small slot. Moving them onto Phi-4 Mini 3.8B means the constant background chatter of an Atlas session costs nothing, and because it is Free (self-hosted), that stays true no matter how many background sessions you run.
What can Phi-4 Mini 3.8B not do inside Atlas?
Phi-4 Mini 3.8B (Ollama) cannot do multi-file refactors. 3.8B of capacity is not enough for that work, so use Phi-4 Mini for tool routing, titles, and summaries and leave the main model slot pointed at a larger coder tag that can hold a real change in its head.
There is a second limit worth naming plainly: keep Atlas permissions on ask, since a small model producing well-formed tool calls is not the same as producing correct ones. Phi-4 Mini 3.8B will emit a syntactically perfect call to the wrong file if it misreads the task. Atlas computes a unified diff for every file edit and surfaces it for approval before writing, and Atlas snapshots file changes as git patches so edits can be diffed and rolled back, which are the right safety rails for a 2.5GB model with tool access. Well-formed is a syntax property. Correct is not.
Can Phi-4 Mini 3.8B handle mixed-language repositories?
Phi-4 Mini 3.8B (Ollama) is multilingual, so mixed-language repos and non-English commit history do not derail it. For an Atlas small_model that job matters, since summarizing a session or titling work in a repository with non-English comments is exactly where a monolingual small model degrades quietly.
Atlas reads git branches, status, and diffs, and can stage and create commits on your behalf, which means the small model sees commit messages routinely. A 128K tokens (131,072) context from a 2.5GB download gives Phi-4 Mini 3.8B room to read a long history or a long transcript before it summarizes. Roughly 4.5GB to serve means it runs on almost any machine, including laptops that could never host a coder tag. That combination, multilingual, long-window, tool-capable, tiny, is unusual and is the reason Phi-4 Mini 3.8B occupies the small slot rather than a general 7B.
When should you pick a different model than Phi-4 Mini 3.8B?
Pick a larger model whenever Phi-4 Mini 3.8B (Ollama) would be doing the building rather than the routing. 3.8B of capacity is not enough for multi-file refactors, so the main model slot in Atlas belongs to a coder tag while phi4-mini:3.8b holds small_model.
Phi-4 Mini 3.8B is the right answer for the Atlas small slot on any machine, and it is a reasonable single model only when your hardware truly cannot serve anything larger. Even then, keep Atlas permissions on ask. Atlas lets you switch the active model and provider on the fly with favorites and recents, so running phi4-mini:3.8b in the small slot and a coder in the main slot is the intended arrangement. Point the index at the Ollama embedder; the small model, the build model, and the vectors then all live on one machine, and the whole stack is Free (self-hosted).
Setup
- 01Pull it: ollama pull phi4-mini:3.8b (2.5GB, aliased to :latest).
- 02In atlas.json register phi4-mini:3.8b under the ollama provider with limit.context 131072 and limit.output 8192.
- 03Set small_model to ollama/phi4-mini:3.8b so Atlas subagents, titles, and summaries all run on a free local model.
- 04Leave model on a larger coder tag and use /models to confirm both resolve.
- 05Point the index at the Ollama embedder; the small model, the build model, and the vectors then all live on one machine.
Frequently asked questions
- how to set phi-4 mini as the atlas small_model
- Run ollama pull phi4-mini:3.8b (2.5GB), register phi4-mini:3.8b under the ollama provider in atlas.json with limit.context 131072 and limit.output 8192, then set small_model to ollama/phi4-mini:3.8b.
- which small local model supports function calling
- Phi-4 Mini 3.8B (Ollama) has function calling as an advertised, trained capability rather than an emergent hope, which is rare below 7B and exactly what a tool-calling agent runtime like Atlas needs.
- what is phi-4 mini's context window
- Phi-4 Mini 3.8B (Ollama) has a 128K tokens (131,072) context from a 2.5GB download, roughly 4.5GB to serve.
- can phi-4 mini 3.8b do refactoring
- No. 3.8B of capacity is not enough for multi-file refactors. Use Phi-4 Mini 3.8B for tool routing, titles, and summaries, and leave the main Atlas model slot on a larger coder tag.
- how much vram does phi4-mini need
- Phi-4 Mini 3.8B is a 2.5GB download and takes roughly 4.5GB to serve, so it runs on almost any machine, including laptops that cannot host a coder tag.
- is phi-4 mini safe to give tool access
- Keep Atlas permissions on ask. A small model producing well-formed tool calls is not the same as producing correct ones, and every Atlas tool call is permission-gated against allow, ask, and deny rules before it runs.
- does phi-4 mini work on non-english codebases
- Yes. Phi-4 Mini 3.8B is multilingual, so mixed-language repos and non-English commit history do not derail it, which matters for the summarize and title slots in Atlas.
Try Atlas in your terminal
The terminal-native AI coding agent. Free core, single binary.
Install AtlasRelated guides
Atlas for .NET: Your AI Coding Agent in 2026
Atlas empowers .NET developers in 2026 with a terminal-native AI coding agent. Securely integrate Atlas with ASP.NET Core for web APIs and services, leveraging local embeddings and robust safety features for efficient
Atlas vs OpenAI Codex CLI: Terminal AI Coding Agents in 2026
Comparing Atlas and OpenAI Codex CLI for terminal AI coding in 2026. Atlas offers a TUI, permission-gated tools, and BYO models, while OpenAI Codex CLI provides sandboxed execution and OpenAI model integration.
Atlas vs Tabby: Terminal AI Coding Agents in 2026
Atlas and Tabby comparison for 2026. Atlas offers terminal-native TUI with permission-gated tools and diff review. Tabby provides self-hosted GPU completion and a cloud agent.
Atlas vs Codebuff: Terminal AI Coding Agents in 2026
Atlas and Codebuff are terminal AI coding agents for 2026. Compare Atlas's terminal-native TUI, permission-gated tools, and diff review with Codebuff's multi-agent system and flexible pricing.
Atlas for Java in 2026
Adopt Atlas, the terminal-native AI coding agent, for Java development in 2026. Enhance your workflow with intelligent code search, refactoring, and robust safety features for Maven and Gradle projects.
Atlas vs Augment Code: Choosing a Terminal AI Coding Agent in 2026
In 2026, Atlas offers a free, terminal-native AI agent with local embeddings and robust safety. Augment Code's Cosmos platform provides shared memory for teams at $100/month.
Atlas for dbt: Terminal-Native AI Coding in 2026
Atlas is a terminal-native AI coding agent for dbt. Read the ref() DAG, convert a table model to incremental, run dbt build against dev, and add tests in 2026.
Atlas vs Cursor: terminal AI coding agents compared (2026)
A grounded 2026 comparison of Atlas and Cursor across workflow, change review, extensibility, and pricing for developers choosing an AI coding agent.