Moonshot Coding & long context
Kimi K2.7 Code
Keep a codebase, its documents and its next change in one conversation.
Kimi K2.7 Code is a Moonshot route for long-context code and document workflows. TokenHot lists function calling, structured output and a 256K context value. Use it for project Q&A, code review and everyday agentic programming when the request benefits from Chinese or multilingual source material staying together.
- Code-focused route
- 256K context
- Function calling
The code suffix describes the TokenHot route identity, not an automatic promise of repository access or code execution. Kimi K2.7 Code and its highspeed sibling must be evaluated as separate model IDs.
AI Chat
Send a prompt and see the response here.
kimi-k2.7-codeStart a conversation with this model and ask follow-up questions.
USD /1M tokens
Pricing
| Group | Input | Output | Cache Read |
|---|---|---|---|
| default | $0.975 | $4.049955 | $0.195 |
| kimi-0.9 | $0.8775 | $3.64496 | $0.1755 |
Public list prices are shown in USD. Final charges may vary by account group and usage tier.
Overview
What is Kimi K2.7 Code?
The route accepts text and returns text, with tool use, function calling, structured output and long context listed in the catalog. Those flags describe available route features; your integration still validates schemas and executes tools.
A good code task names the repository state, expected behavior and review standard. Keep generated patches small enough to inspect and test, especially when the request spans many files.
Answer from the project, not memory
Provide file paths, versions and the relevant symbols. Ask for citations or snippets so an engineer can verify the explanation.
Design for a clean diff
State invariants and acceptance tests before asking for code. Prefer a focused patch over a broad rewrite.
Preserve terminology
Give the source language and intended audience. Require technical terms, API names and unresolved translations to remain explicit.
From brief to deliverable
Put Kimi K2.7 Code to work
Engineers onboarding to a codebase
Build a map of an unfamiliar project
Ask for a component map, entry points and high-risk boundaries from the supplied tree and docs. Use it to plan the next investigation, not to replace reading the code.
- Tools you need
- Repository search and a local test runner for confirmation.
- Keep in mind
- A map inferred from filenames can be wrong; verify each boundary against source code.
View a task brief
Create an architecture map from the supplied repository tree and documents. Link each major claim to a file or section, flag uncertain boundaries and propose the smallest set of searches and tests that would confirm the map.
Engineering teams
Prepare a change for review
Use the issue, current implementation and expected behavior to draft a patch with tests and a review summary.
- Tools you need
- Source access and the project test command.
- Keep in mind
- Do not claim a test passed unless the command was actually run and its output is supplied.
View a task brief
Propose a focused patch for the supplied issue. Include the intended diff, regression cases and reviewer notes. Separate commands to run from commands already run, and preserve the existing public interface unless the requirement says otherwise.
Platform and SDK teams
Turn API docs into typed tool calls
Extract endpoint rules from supplied documentation and return a schema-ready function definition plus examples that respect required fields.
- Tools you need
- A schema validator and the application that owns credentials.
- Keep in mind
- Never invent a field or claim the provider accepts a parameter absent from the supplied docs.
View a task brief
Convert the supplied API documentation into typed tool definitions. Preserve exact field names, identify required and optional values, add invalid examples and flag any ambiguity for human review. Do not include credentials or invent undocumented parameters.
Capabilities in context
Key features
| Feature | What you get | Why it matters |
|---|---|---|
| Context capacity | 256K tokens shown in the catalog | Keep related files and documents together, but use retrieval and source links to avoid burying the decisive evidence. |
| Code route | Text input and text output | Code generation and review remain text workflows; execute, compile and test in your own environment. |
| Function calling | Function calling is listed by the catalog | Validate arguments before execution and return tool results with stable names and error states. |
| Structured output | Structured output is listed by the catalog | Use JSON schemas for issue lists, plans or code metadata, then handle malformed output explicitly. |
| Highspeed sibling | Kimi K2.7 Code highspeed is a separate route | Treat latency and quality as measured properties of the selected model ID. |
The route capabilities and model ID come from TokenHot's live catalog. Verify protocol parameters and compare the standard and highspeed routes before production changes.
Audience & fit
Where Kimi K2.7 Code fits
Teams maintaining multilingual codebases
Use project-local terminology and source citations to keep code explanations aligned with the repository rather than generic patterns.
Engineers reviewing multi-file changes
Ask for a focused diff, tests and a risk summary. Keep execution and merge decisions in the existing development workflow.
SDK and platform teams
Turn documentation into schema-checked tools, and keep undocumented behavior out of generated contracts.
Cost context
Plan the cost of a useful result
Price the review loop
Code tasks often include retries, test runs and human correction. Compare the cost of an accepted patch, not only the initial completion.
Cache shared instructions carefully
Large repository conventions can repeat across requests. Measure cache reads and writes with the exact route and account group.
Pin the model ID
The highspeed sibling and future revisions are separate dependencies. Record the exact ID in logs and migration notes.
Use the current pricing table for available rates and account groups. Model IDs and prices come from TokenHot’s catalog; provider pricing and subscriptions are separate.
FAQ
Frequently asked questions
What is Kimi K2.7 Code best suited for?
Kimi K2.7 Code is suited to the input, output, and capability types listed on this page. Test production workloads before choosing it for a critical system.
How is Kimi K2.7 Code priced?
Pricing is shown in the pricing section above. Actual cost depends on usage volume, account group, and the request payload.
How can I call Kimi K2.7 Code?
Use the model ID shown above with one of the supported API protocols. Code examples are provided when usage data is available.
Does Kimi K2.7 Code include a coding environment?
No. It is an API route. Repository access, shell execution, credentials and merge controls stay in your application or development environment.
Can it return structured tool arguments?
The TokenHot catalog lists structured output and function calling. Validate the returned schema and handle missing or invalid arguments before execution.
How is the Code route different from highspeed?
They are separate model IDs. Measure quality, latency, corrections and total cost on your own code tasks instead of assuming the suffix defines the result.
What makes a code prompt useful?
Include the current behavior, relevant files, constraints and acceptance tests. Ask the model to identify unknowns before proposing a broad change.
Get started
Build with Kimi K2.7 Code
API