AnthropicText Generation Model
Claude Fable 5
Anthropic's frontier model, built for the hardest reasoning and long-horizon agentic work. A 1M-token context window and adaptive thinking let it sustain complex, multi-step tasks — deep research, large-scale refactors, autonomous coding sessions — that shorter-context models can't hold together.
import OpenAI from "openai";
const openai = new OpenAI({
baseURL: "https://api.inference.net/v1",
apiKey: "<YOUR_API_KEY>",
});
const completion = await openai.chat.completions.create({
model: "claude-fable-5",
messages: [
{
role: "user",
content: "What is the meaning of life?"
}
],
stream: true,
});
for await (const chunk of completion) {
process.stdout.write(chunk.choices[0]?.delta.content as string);
}import OpenAI from "openai";
const openai = new OpenAI({
baseURL: "https://api.inference.net/v1",
apiKey: "<YOUR_API_KEY>",
});
const completion = await openai.chat.completions.create({
model: "claude-fable-5",
messages: [
{
role: "user",
content: "What is the meaning of life?"
}
],
stream: true,
});
for await (const chunk of completion) {
process.stdout.write(chunk.choices[0]?.delta.content as string);
}