Spiral gives your agent every tool with one account. Browse the tools →

VS Code · LLMReleased 2026-11-16

How to Use Hy4 Flash in VS Code

Hy4 Flash is suited to document editing, research briefs, slide outlines, and simple frontend demos. Tencent recommends Hy4 for more demanding work such as long-horizon software engineering.

Prompts to try with Hy4 Flash in VS Code

Copy an example into VS Code, or ask in your own words.

Use Hy4 Flash to build a searchable FAQ demo from this project's README. Show matching questions as I type, include an empty-results message, and check that clearing the search restores all questions.

Hy4 FlashVS Code
Try asking
  • Use Hy4 Flash to revise this project's getting-started document for a new contributor. Preserve commands exactly, flag contradictions, and show the proposed changes.

  • Use Hy4 Flash to turn the project's architecture notes into a six-slide outline. Give each slide one main claim, supporting points, and a speaker note tied to the source document.

  • Use Hy4 Flash to investigate the spreadsheet formulas in this project's CSV-processing examples. Use deeper thinking, reproduce one failing case, and propose the smallest correction with a checkable expected result.

  • Use Hy4 Flash to compare the requirements document with the current demo. Return a table of requirements, relevant files, observed behavior, and missing work. Keep the review limited to the demo.

How to set up Hy4 Flash in VS Code

Pick the way that suits you. Each takes about two minutes.

Use Spiral's MCP server

  1. Add the hosted server

    Use Add to VS Code on the console's Agents & MCP page, or run:

    code --add-mcp '{"name":"spiral","type":"http","url":"https://api.spiral.ai/mcp"}'
  2. Sign in

    VS Code asks you to sign in when it first starts the server: sign in to Spiral and click Authorize. No API key. Run MCP: List Servers from the Command Palette to check that Spiral is running.

Use the Spiral skill

  1. Send VS Code this message

    Your agent reads Spiral's skill and sets itself up.

    set up https://spiral.ai/SKILL.md
  2. Sign in or paste a key

    Approve Spiral in the browser, or give the agent a key from the console.

Use the Spiral CLI

  1. Install and sign in

    Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

    npx -y spiral-cli@latest init

Call the Spiral API

  1. Create an API key

    In the console, under API keys.

  2. Run Hy4 Flash

    One request; the result comes back by polling or a webhook.

    curl https://api.spiral.ai/v1/runs \
      -H "Authorization: Bearer $SPIRAL_API_KEY" \
      -H "Content-Type: application/json" \
      -H "Idempotency-Key: $(uuidgen)" \
      -d '{
        "provider": "openrouter",
        "model": "tencent/hy4-flash",
        "input": {
          "messages": [
            {
              "role": "user",
              "content": "Hello!"
            }
          ]
        }
      }'

Then paste one of the prompts above: VS Code finds Hy4 Flash on Spiral, shows the price and runs it.

Hy4 Flash providers and prices

Spiral runs Hy4 Flash through OpenRouter. Open a card for today's price, with every fee included.

OpenRouterLLM
Tencent: Hy4 flash
tencent/hy4-flash

Settings you can ask for

Ask VS Code for any of these in your prompt.

SettingAllowed valuesDefaultDescription
Max tokens1 to 65536

The most output tokens to generate. On a reasoning model the reasoning tokens count toward it: a cap too low for the effort can end with no answer (finish_reason length).

Temperature0 to 2

Every API field of Tencent: Hy4 flash is on its tool page: open its card above.

What can you do with Hy4 Flash in VS Code?

Build simple frontend demos and revise project documentation with Hy4 Flash. Give the agent a bounded task and an observable result to check.

Research briefs

Turn collected source passages into a decision brief with supporting evidence and unanswered questions.

Document revisions

Revise a draft for a specific audience while preserving its claims, figures, and terminology.

Presentation outlines

Convert a written brief into slide titles, supporting points, and speaker notes.

Simple frontend demos

Build a small interface from a written brief, with explicit acceptance criteria for each control.

Spreadsheet formula repair

Review formulas and sample rows, propose a correction, and explain how to check the result.

Recurring document reviews

Compare successive document texts and draft a digest of changed claims, figures, and instructions.

Questions about Hy4 Flash in VS Code

Can VS Code use Hy4 Flash?

Yes. Add Spiral to VS Code as an MCP server, and VS Code can find and run Hy4 Flash like any built-in tool.

How much does Hy4 Flash cost in VS Code?

Up to $0.000751 per run at the default inputs. $0.0455 per 1M input tokens, $0.18265 per 1M output tokens. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your VS Code plan is separate.

Do I need an OpenRouter account to use Hy4 Flash in VS Code?

No. Spiral runs Hy4 Flash on its own OpenRouter account. You sign in to Spiral once and never paste a key.

How long does it take to set up Hy4 Flash in VS Code?

About two minutes: add the hosted server, then sign in.

Does VS Code wait while Hy4 Flash runs?

Hy4 Flash runs in the background. VS Code starts the run, checks on it and gives you the text, json when it's ready.

What is Hy4 Flash good at?

Tencent recommends it for everyday document work, research, presentation creation, and simple frontend demos. Start with a concrete deliverable, such as a revised document or a six-slide outline.

When should I choose Hy4 instead?

Tencent recommends Hy4 for complex work such as long-horizon software engineering. Keep Hy4 Flash tasks focused, such as building one demo or revising one document.

How much context does Hy4 Flash support?

Tencent documents support for up to 1 million tokens of context. That context capacity is separate from the maximum length of a generated answer.

How long can a Hy4 Flash answer be?

Tencent lists a maximum output of 64k tokens. For a long deliverable, request an outline first, then draft and review each section.

Can Hy4 Flash reason before answering?

Yes. Tencent documents direct-answer and deeper-thinking modes. Try deeper thinking for formula diagnosis or comparing conflicting evidence, and direct answers for straightforward editing.

Get started

Start using Hy4 Flash in VS Code

One Spiral account for every tool your agent needs. No subscription; you pay per run.

Paste this into VS Code:

Set up VS Code

set up https://spiral.ai/SKILL.md
Are you an AI agent? See setup options