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

opencode · LLMReleased 2023-08-02

How to Use Weaver Alpha in opencode

Weaver Alpha is for descriptive fiction, character dialogue, and roleplay that calls for longer replies. It aims for Claude-style verbosity, with an explicit warning that coherence and memory will fall short of Claude.

Prompts to try with Weaver Alpha in opencode

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

Use Weaver Alpha to draft 12 lines of dialogue for the harbor guard using the project's character notes. Keep each line under 20 words, preserve the guard's distrust of strangers, and show me the draft before editing files.

Weaver Alphaopencode
Try asking
  • Read the project's lighthouse quest outline, then use Weaver Alpha to write a 350-word arrival scene. Keep all established names and locations, use second person, and stop before the player enters the tower.

  • Use Weaver Alpha to draft three responses to the player's refusal of the merchant's offer, based on the project's dialogue tree. Make them angry, disappointed, and amused, with no new quest facts.

  • From the project's lore notes, prepare a brief under 1,000 words and use Weaver Alpha to draft a 250-word journal entry by the missing cartographer. Keep the island's secret out of the entry.

  • Use Weaver Alpha to rewrite the project's opening tavern description in 200 words with a more uneasy tone. Preserve the exits, objects, and people already listed, and return prose for review.

How to set up Weaver Alpha in opencode

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

Use Spiral's MCP server

  1. Add the server

    Leave out --global to add Spiral to the current project only. No header and no client ID or secret: opencode registers itself with Spiral.

    opencode mcp add spiral --global --url https://api.spiral.ai/mcp
  2. Sign in

    Your browser opens. Sign in to Spiral, pick the organization and click Authorize, then return to the terminal. No API key. Inside opencode, /mcps starts the same sign-in.

    opencode mcp auth spiral
  3. Check it

    Spiral shows as connected.

    opencode mcp list

Use the Spiral skill

  1. Send opencode 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 Weaver Alpha

    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": "mancer/weaver",
        "input": {
          "messages": [
            {
              "role": "system"
            }
          ]
        }
      }'

Then paste one of the prompts above: opencode finds Weaver Alpha on Spiral, shows the price and runs it.

Weaver Alpha providers and prices

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

OpenRouterLLM

Settings you can ask for

Ask opencode for any of these in your prompt.

SettingAllowed valuesDefaultDescription
Seeda whole number
Min p0 to 1
Top ka whole number from 0
Top p0 to 1
Logprobson or off
Max tokens1 to 6000

The most output tokens to generate.

Temperature0 to 2
Top logprobs0 to 20
Presence penalty-2 to 2
Frequency penalty-2 to 2
Repetition penalty0 to 2

Every API field of Mancer: Weaver (alpha) is on its tool page: open its card above.

What can you do with Weaver Alpha in opencode?

Create dialogue, quest descriptions, and scene drafts for a game project. Have your coding agent supply a compact brief from the project's lore, then review the prose before adding it to the game.

Game character dialogue

Ask Weaver Alpha for a conversation between a suspicious innkeeper and a stranded traveler. Supply each character's motive and the information they must withhold.

Short story scenes

Give Weaver Alpha an outline for one scene and request a prose draft with a fixed viewpoint, a clear conflict, and a specific stopping point.

Tabletop encounter narration

Use Weaver Alpha to draft a location introduction and an NPC's opening speech. Keep hidden information separate from the text players will hear.

Interactive fiction branches

Ask Weaver Alpha for three short responses to a player's decision. State the story facts that every branch must preserve, then review the results for contradictions.

Character voice exploration

Have Weaver Alpha write the same apology as a proud captain, a frightened apprentice, and an evasive merchant. Compare the dialogue before choosing a voice.

Fictional letters and journals

Ask Weaver Alpha for an in-world letter or diary entry based on a short character brief. Specify what the writer knows and what they misunderstand.

Alternate scene drafts

Give Weaver Alpha one scene brief and request separate versions emphasizing tension, melancholy, or humor. Preserve the same events so you can compare tone.

Questions about Weaver Alpha in opencode

Can opencode use Weaver Alpha?

Yes. Add Spiral to opencode as an MCP server, and opencode can find and run Weaver Alpha like any built-in tool.

How much does Weaver Alpha cost in opencode?

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

Do I need an OpenRouter account to use Weaver Alpha in opencode?

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

How long does it take to set up Weaver Alpha in opencode?

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

Does opencode wait while Weaver Alpha runs?

Weaver Alpha runs in the background. opencode starts the run, checks on it and gives you the text, json when it's ready.

What is Weaver Alpha best used for?

Its stated focus is roleplay and narrative writing with verbose replies. Try it for descriptive scenes, fictional conversations, and character monologues.

Does Weaver Alpha write like Claude?

It attempts Claude-style verbosity. Its description explicitly warns that coherence and memory do not reach the same level, so review continuity before accepting a draft.

How much can Weaver Alpha write in one response?

The maximum output is 6,000 tokens, within an 8,000-token context window. Leave room for the reply when supplying character notes and previous dialogue.

How should I prompt Weaver Alpha for an ongoing story?

Given the stated memory limitation, include a short recap, the current scene, and the facts that must stay fixed. Ask for one scene at a time and check each draft against those notes.

How do I make Weaver Alpha's revisions more predictable?

Lower the temperature and keep the creative brief unchanged while comparing drafts. Treat this as a sampling adjustment, not a guarantee of accurate continuity.

Get started

Start using Weaver Alpha in opencode

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

Paste this into opencode:

Set up opencode

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