Skip to content

Tools

AI coding assistant

By Ofrai Editorial (AI Model Curators)

Treat DeepSeek Flash as the everyday compiler-adjacent chat, then escalate to Pro, GPT, or Claude when you need a review you would actually merge.

Open studio

Chat and video use credits from your Ofrai balance.

Suggested loop

Paste the failing test, ask Flash for a patch, run it locally, then ask Claude or GPT to explain the risk. That mix is why Ofrai lists more than one text model. Work in three movements. First, movement is cheap and fast: Flash turns the failing evidence into a candidate diff. Second, you run it, because the model cannot run it. Third, movement is the review: a premium model reads the diff you actually got, not the one you hoped for.

The loop is deliberately small at the start and expensive only at the end, which is why a chat-based assistant beats one giant prompt for most debugging work.

Docs

Upload a PDF spec and ask questions in the same thread — see chat-with-PDF. Image Studio is optional for diagrams, and it is genuinely optional: architecture sketches usually cost more in review time than a blank canvas costs in credits. The valuable move is keeping the document in the loop instead of summarizing it from memory. Ask the model to quote the clause it is answering from, so you can check the source before you trust the conclusion.

When to switch to chat-with-PDF

When the source of truth is a spec sheet or RFC, attach the PDF in Text Studio and ask questions in the same thread. Switch back to coding iterations when the doc question is answered.

Pair coding with chat-with-PDF

Open the spec PDF in chat-with-PDF, then keep the same thread for the coding loop. The doc question and the patch live next to each other in one Chat studio.

Which engine takes which job

Route by job, not by brand. DeepSeek V4 Flash is the cheap loop: reading a stack trace, renaming a symbol across three files, writing a first-draft test, explaining a regex nobody remembers writing. DeepSeek V4 Pro is the mid-tier workhorse for multi-file refactors where you want the model to hold a longer plan before it answers. GPT-5 fits ambiguous product questions where the requirement is fuzzy and you need options rather than a patch.

Claude Sonnet is the reviewer: hand it the diff and ask what breaks, because its structured explanations are the ones you can paste into a pull request. One rule keeps the spend down: draft on Flash, escalate once, never escalate twice for the same change. The DeepSeek vs Claude page goes deeper if you need a permanent default rather than a per-task routing habit.

Prompt shapes for real code work

Brief the model the way a colleague would brief you, in four parts: the failing evidence, the constraint you cannot break, the shape of the answer, and what you want explained.

A bug fix reads like this — "tests/test_cart.py::test_apply_discount fails with DiscountError on orders over 100. The pricing service raises on zero-quantity lines but the API can send one. Give me a minimal patch that guards the zero-quantity case in apply_discount, keep the public signature, do not touch the rounding, and tell me which other call sites could hit the same path."

A new module needs a different shape: "write a TypeScript retry helper with exponential backoff, full jitter, a hard cap of five attempts and AbortSignal support; return the last error instead of throwing; document the defaults."

For a refactor, paste the before and after shapes instead of describing intent. That version works because the model can review real code instead of guessing at it.

Holding codebase context in a chat box

Ofrai does not host your repository, so context management is the actual skill. Build a compact briefing rather than pasting 400 lines: the public signature, the two or three files it touches, the exact error string, the runtime and library versions, and the constraint that must not change. That is usually under 200 lines and produces better answers than a full dump, because the model spends attention on the code you flagged instead of boilerplate it never needed.

When a thread gets long or the model contradicts its own earlier answer, start a fresh thread with a written summary — "the guard now lives in apply_discount, the rounding change was reverted, the remaining failure is in the shipping-rate path" — rather than scrolling back. Stale context is the quiet cause of most bad second drafts.

Review passes before you merge

Read model output as a patch from a stranger who is usually right. Pass one: ask for the diff alone, no prose, and read it as a diff. Pass two: ask what input breaks it — empty string, null, a very large file, two calls made at the same time, a locale where the translated string is blank. Pass three: ask which existing test should have caught this, and which one you owe the repo. Then run the suite yourself, because the model cannot.

For anything touching auth, money or migrations, escalate the review to a premium model with a narrow instruction: "list only the correctness risks in this diff, ranked, no summary." That framing returns a checklist instead of an essay, and a checklist is what you can act on in the ten minutes before merge.

Where generated code quietly breaks

Five failures cover most of it. Invented APIs: the model calls a helper that does not exist in your version of the library, so pin the version in the prompt and require documented calls only. Silent behaviour change: a rewrite drops an error branch because nothing tested it, which is exactly what pass two is for. Over-broad patches: a twelve-line fix delivered as a refactor of four files, met by asking for the minimal change first and the refactor as a separate request.

Boundary bugs at empty, zero and single-item collections. And plausible-but-wrong domain logic, the only one your own knowledge can catch, so state the business rule out loud. The fix for all five is identical: ask for the smallest change that makes the test pass, then read it as if it came from an interview candidate.

Settings worth changing before you prompt

Temperature is the first dial and most people leave it wrong. Keep it low, roughly 0.2 to 0.4, for anything you intend to run: bug fixes, refactors, migrations, generated tests. Raise it only when you are deliberately shopping for options — three design sketches, three naming schemes, three approaches to the same design problem. On the premium models, reasoning budget moves answers further than temperature does, so give a hard problem room to think instead of asking for a longer reply.

Context length is the other one worth managing: paste the failing code plus the interface it must satisfy rather than the whole file, and the answer stays focused. And keep any system instruction short and stable for the length of a session; a long, constantly rewritten instruction is the reason the same prompt returns three different styles in one afternoon.

What a debugging session costs

Text jobs bill by tokens, so a debugging loop has a predictable cost shape: many small Flash calls, one or two Pro calls, and one premium review. The habit that ruins the budget is re-asking the premium model the same question after a one-line edit, paying full price for a conclusion you already held. The largest saving is fixing the prompt instead of the model: write the failing evidence into the prompt, state the constraint, and most of the time Flash answers it and nothing escalates.

The second saving is refusing to generate tests that cannot change the outcome. The third is keeping exploration cheap and reserving premium calls for changes you would defend in review. On Ofrai the same wallet pays for images and video, so an unbounded coding afternoon is a real reason the evening clip never happens.

Who should skip a chat-based coding assistant

Skip it if your workflow depends on repo-wide awareness, automatic test runs, or knowing what changed since the last commit — an agent with your git history answers those, and a chat window cannot. Skip it if you need an auditable trail, because the evidence lives in your IDE and CI rather than in a text thread. And skip it for decisions where correctness is judged by domain authority — pricing rules, tax logic, consent flows — where the model should draft and a human must decide.

It is a strong fit for test writing, boilerplate removal, clearer log and error messages, script glue, migration drafts, and explaining unfamiliar code to someone new on the team. The honest test: if a wrong answer would be caught by your suite within a minute, go ahead; if it would ship, use it for the draft and read every line yourself.

Coding chat versus the writing tool next door

Both live in Text Studio and both draw on the same credits, so the only real difference is what you ask the thread to produce. A writing request ends in a finished prose artifact — an article, a landing page, an email — where tone and structure are the deliverable. A coding request ends in something you execute: a diff, a test, a migration, where correctness and interface compatibility are the deliverable and prose is scaffolding around it.

Model choice follows that difference, since the writing tool leans on whichever engine holds voice best on long drafts while the coding loop leans on cheap Flash for volume and a premium reviewer at the end. Keeping the two separate in your head is what stops a good paragraph from turning into a bad patch. The AI writing page covers the prose side if you need both.

Open studio

FAQ

Do you host repos?
No. Ofrai is the model workspace. Keep git where it already lives.
DeepSeek vs Claude for code?
Flash for volume, Claude or GPT for the write-up. Details on the DeepSeek vs Claude page.
How much does a generation cost?
Each job lists Ofrai credits in the studio. Catalog credits are starting points; resolution and duration can change the final spend.
How do I start on Ofrai?
Open Image or Video Studio from this page, pick a recommended model, paste or adapt the starter prompt, and generate from your library.
What is the AI coding assistant on Ofrai?
A multi-model chat in Text Studio tuned for code: DeepSeek Flash for cheap loops, Claude or GPT for the merge-ready explanation. Same workspace as chat-with-PDF and writing.

Related models

Compare