diff --git a/packages/website/src/freeProviders.ts b/packages/website/src/freeProviders.ts new file mode 100644 index 0000000..4950688 --- /dev/null +++ b/packages/website/src/freeProviders.ts @@ -0,0 +1,121 @@ +export type FreeTierBadge = 'best' | 'no-card' | 'trial'; + +export type FreeProvider = { + id: 'groq' | 'openrouter' | 'anthropic' | 'openai'; + name: string; + badge?: FreeTierBadge; + badgeLabel?: string; + summary: string; + creditCard: string; + limits: string; + lexaiModel: string; + signupUrl: string; + docsUrl: string; + steps: string[]; +}; + +export const FREE_PROVIDER_BADGES: Record = { + best: 'Best free option', + 'no-card': 'No card needed', + trial: 'Trial credits', +}; + +/** How to use LexAI at $0 — provider free tiers as of 2026. Limits change; verify on each site. */ +export const FREE_PROVIDERS: FreeProvider[] = [ + { + id: 'groq', + name: 'Groq', + badge: 'best', + badgeLabel: 'Best free option', + summary: + 'Ongoing free API access with no credit card. Rate limits apply, but there is no per-token charge on the free tier — ideal for daily writing help and light coding assist.', + creditCard: 'Not required', + limits: 'Rate-limited (roughly 30 requests/min; daily caps vary by model). Check the Groq console for your org.', + lexaiModel: 'llama-3.3-70b-versatile', + signupUrl: 'https://console.groq.com/keys', + docsUrl: 'https://console.groq.com/docs/overview', + steps: [ + 'Create a Groq account at console.groq.com — no payment method needed.', + 'Generate an API key under API Keys.', + 'In LexAI Options (Chrome), Settings (VS Code), or LEXAI_PROVIDER=groq (CLI): choose Groq, paste the key.', + 'Optional: set model to llama-3.1-8b-instant for faster, lighter requests on tighter limits.', + ], + }, + { + id: 'openrouter', + name: 'OpenRouter', + badge: 'no-card', + badgeLabel: 'No card needed', + summary: + '25+ models at $0 per token via the :free suffix or the openrouter/free router. One API key covers many models — good for experimenting before you commit to a host.', + creditCard: 'Not required for free models', + limits: + 'About 20 requests/min. ~50 free requests/day without credits; ~1,000/day after a one-time $10 credit purchase (credits never expire).', + lexaiModel: 'openrouter/free', + signupUrl: 'https://openrouter.ai/settings/keys', + docsUrl: 'https://openrouter.ai/docs/guides/routing/model-variants/free', + steps: [ + 'Sign up at openrouter.ai and create an API key.', + 'In LexAI, choose OpenRouter and paste the key.', + 'Set model to openrouter/free (auto-picks a free model) or a specific slug such as meta-llama/llama-3.3-70b-instruct:free.', + 'Optional: add $10 in credits once to raise the daily free-model cap to ~1,000 requests — still $0 per token on free routes.', + ], + }, + { + id: 'anthropic', + name: 'Anthropic', + badge: 'trial', + badgeLabel: 'Trial credits', + summary: + 'New Console accounts receive a small one-time API credit (often around $5) with no card required to claim. Enough to try Claude-powered writing and Code Assist before prepaid billing.', + creditCard: 'Not required to claim starter credit', + limits: 'One-time credit balance; then pay-as-you-go. Use Haiku models to stretch the trial further.', + lexaiModel: 'claude-3-5-haiku-20241022', + signupUrl: 'https://console.anthropic.com/', + docsUrl: 'https://docs.anthropic.com/en/api/getting-started', + steps: [ + 'Create an account at console.anthropic.com and claim the new-user API credit.', + 'Create an API key under API Keys.', + 'In LexAI, choose Anthropic, paste the key, and keep the default Haiku model for lowest cost.', + 'When credits run out, add prepaid balance or switch to Groq or OpenRouter for ongoing free usage.', + ], + }, + { + id: 'openai', + name: 'OpenAI', + badge: 'trial', + badgeLabel: 'Limited trial', + summary: + 'No permanent free API tier. Some new accounts still receive a short-lived trial credit; otherwise a minimum prepaid purchase is required. Mentioned for completeness — Groq or OpenRouter are better $0 paths.', + creditCard: 'Required for ongoing use; trial availability varies', + limits: 'Trial credits (if offered) expire after a few months. Prepaid billing from about $5 minimum after trial.', + lexaiModel: 'gpt-4o-mini', + signupUrl: 'https://platform.openai.com/api-keys', + docsUrl: 'https://platform.openai.com/docs/guides/rate-limits', + steps: [ + 'Create an account at platform.openai.com and check Billing for any trial balance.', + 'If trial credit is available, create an API key and use it in LexAI with provider OpenAI.', + 'Prefer gpt-4o-mini to conserve tokens during evaluation.', + 'For sustained free usage, use Groq or OpenRouter instead — OpenAI is pay-as-you-go after any trial.', + ], + }, +]; + +export const LEXAI_FREE_HIGHLIGHTS = [ + { + title: 'LexAI is always $0', + body: 'No LexAI subscription, account, or backend. You only connect a provider API key you control.', + }, + { + title: 'Same key, three apps', + body: 'Chrome extension, VS Code / Cursor, and CLI Prompt Builder all use the same supported providers.', + }, + { + title: 'Start with Groq or OpenRouter', + body: 'Both offer real ongoing free API access without a credit card — enough for grammar fixes, rewrites, and light Code Assist.', + }, + { + title: 'Your key stays local', + body: 'Keys are encrypted in Chrome, stored in VS Code Secret Storage, or read from env in the CLI — never sent to LexAI.', + }, +] as const; diff --git a/packages/website/src/pages/DocsPage.tsx b/packages/website/src/pages/DocsPage.tsx index bc14abb..eee2a1a 100644 --- a/packages/website/src/pages/DocsPage.tsx +++ b/packages/website/src/pages/DocsPage.tsx @@ -1,5 +1,6 @@ import { useEffect } from 'react'; import { Link } from 'react-router-dom'; +import { FREE_PROVIDERS } from '../freeProviders'; import { CHROME_STORE, REPO, VSCODE_MARKETPLACE } from '../links'; function scrollToSection(id: string) { @@ -17,6 +18,7 @@ export function DocsPage() { const nav = [ ['overview', 'Overview'], + ['free', 'Free LLM setup'], ['chrome', 'Chrome'], ['vscode', 'VS Code'], ['cli', 'CLI'], @@ -62,6 +64,91 @@ export function DocsPage() { +
+

Free LLM setup

+

+ LexAI is free — no subscription, no LexAI account. To use it at $0 ongoing, connect a + provider that offers a free API tier. Groq and OpenRouter are the most practical; Anthropic + and OpenAI offer small trial credits but not a permanent free API. +

+

Recommended path

+
    +
  1. + Install LexAI (Chrome, VS Code, or CLI) — see Install. +
  2. +
  3. + Sign up for Groq{' '} + (no credit card) or{' '} + + OpenRouter + {' '} + (no card for free models). +
  4. +
  5. Create an API key on that provider's dashboard.
  6. +
  7. + In LexAI: choose the provider, paste the key, and set the model slug below (Chrome + Options → Model; VS Code Settings → Model; CLI{' '} + LEXAI_MODEL). +
  8. +
  9. Select text and run an action — requests go directly to your provider, not LexAI.
  10. +
+

Providers

+ {FREE_PROVIDERS.map((provider) => ( +
+

{provider.name}

+

{provider.summary}

+
    +
  • + Credit card: {provider.creditCard} +
  • +
  • + Limits: {provider.limits} +
  • +
  • + Suggested LexAI model: {provider.lexaiModel} +
  • +
+

+ Setup +

+
    + {provider.steps.map((step) => ( +
  1. {step}
  2. + ))} +
+
+ + Get API key + + + Provider docs + +
+
+ ))} +

CLI example (Groq, free tier)

+
{`# PowerShell
+$env:LEXAI_API_KEY = "gsk_..."
+$env:LEXAI_PROVIDER = "groq"
+$env:LEXAI_MODEL = "llama-3.3-70b-versatile"
+lexai prompt "rewrite this email to sound more professional"
+
+# bash
+export LEXAI_API_KEY=gsk_...
+export LEXAI_PROVIDER=groq
+export LEXAI_MODEL=llama-3.3-70b-versatile
+lexai prompt "summarize this README"`}
+

CLI example (OpenRouter, free models)

+
{`export LEXAI_API_KEY=sk-or-...
+export LEXAI_PROVIDER=openrouter
+export LEXAI_MODEL=openrouter/free
+lexai prompt "turn this bullet list into a user story"`}
+

+ Limits and trial amounts change. Check each provider's pricing and rate-limit pages + before relying on a free tier in production. +

+
+

Chrome extension

diff --git a/packages/website/src/pages/HomePage.tsx b/packages/website/src/pages/HomePage.tsx index 3e9c0db..da52506 100644 --- a/packages/website/src/pages/HomePage.tsx +++ b/packages/website/src/pages/HomePage.tsx @@ -1,5 +1,6 @@ import { Link, useNavigate } from 'react-router-dom'; import { LogoMark } from '../components/LogoMark'; +import { FREE_PROVIDERS, FREE_PROVIDER_BADGES, LEXAI_FREE_HIGHLIGHTS } from '../freeProviders'; import { CHROME_STORE, REPO, VSCODE_MARKETPLACE } from '../links'; function openDocsSection(navigate: ReturnType, id: string) { @@ -57,7 +58,8 @@ export function HomePage() {

Skip Grammarly and Copilot subscriptions

Writing help on any webpage. Coding assist in VS Code or Cursor. You bring the API key — - LexAI has no account, no servers, and no fee. + LexAI has no account, no servers, and no fee. Use Groq or OpenRouter for ongoing free + API access.

@@ -104,6 +106,66 @@ export function HomePage() {
+
+
+

Use it free

+

LexAI costs nothing — your provider can too

+

+ LexAI never charges a subscription. Connect a free-tier API key from a supported provider + and get Grammarly-style writing help and Copilot-style coding assist without paying + Grammarly or Copilot. +

+
    + {LEXAI_FREE_HIGHLIGHTS.map((item) => ( +
  • + {item.title} +

    {item.body}

    +
  • + ))} +
+
+ {FREE_PROVIDERS.map((provider) => ( + + ))} +
+

+ Rate limits and trial amounts change — verify on each provider's site. Full setup + steps are in{' '} + Free LLM setup. +

+
+
+

Product

diff --git a/packages/website/src/styles.css b/packages/website/src/styles.css index 455d937..05344d8 100644 --- a/packages/website/src/styles.css +++ b/packages/website/src/styles.css @@ -373,6 +373,162 @@ a.package-card { color: var(--muted); } +/* Free tier section */ +.free-highlights { + display: grid; + gap: 0; + list-style: none; + margin: 0 0 2rem; + padding: 0; +} + +@media (min-width: 700px) { + .free-highlights { + grid-template-columns: 1fr 1fr; + column-gap: 3rem; + } +} + +.free-highlights li { + padding: 1rem 0; + border-top: 1px solid var(--line); +} + +.free-highlights strong { + display: block; + margin-bottom: 0.25rem; + font-size: 0.95rem; +} + +.free-highlights p { + margin: 0; + color: var(--muted); + font-size: 0.92rem; +} + +.provider-grid { + display: grid; + gap: 0.75rem; +} + +@media (min-width: 700px) { + .provider-grid { + grid-template-columns: 1fr 1fr; + } +} + +.provider-card { + display: flex; + flex-direction: column; + gap: 0.55rem; + padding: 1.2rem 1.15rem 1.25rem; + border-radius: var(--radius); + background: var(--surface); + border: 1px solid var(--line); +} + +.provider-card-head { + display: flex; + flex-wrap: wrap; + align-items: center; + gap: 0.5rem; +} + +.provider-card strong { + font-size: 0.98rem; + font-weight: 600; +} + +.provider-card > p { + margin: 0; + flex: 1; + color: var(--muted); + font-size: 0.9rem; +} + +.provider-badge { + display: inline-block; + padding: 0.15rem 0.45rem; + border-radius: 4px; + font-size: 0.68rem; + font-weight: 600; + letter-spacing: 0.03em; + text-transform: uppercase; +} + +.provider-badge-best { + background: #eef2ff; + color: var(--indigo-deep); +} + +.provider-badge-no-card { + background: #ecfdf5; + color: #047857; +} + +.provider-badge-trial { + background: #fef9ec; + color: #92400e; +} + +.provider-meta { + display: grid; + gap: 0.45rem; + margin: 0; + font-size: 0.82rem; +} + +.provider-meta dt { + margin: 0; + font-weight: 600; + color: var(--ink); +} + +.provider-meta dd { + margin: 0.1rem 0 0; + color: var(--muted); +} + +.provider-card .more { + font-weight: 500; + font-size: 0.82rem; + color: var(--indigo); + text-decoration: none; +} + +.provider-card .more:hover { + color: var(--indigo-deep); +} + +.free-footnote { + margin: 1.25rem 0 0; + font-size: 0.88rem; + color: var(--muted); +} + +.docs-provider { + margin-top: 1.5rem; + padding-top: 1.25rem; + border-top: 1px solid var(--line); +} + +.docs-provider:first-of-type { + margin-top: 0.75rem; +} + +.docs-provider h4 { + margin: 0 0 0.35rem; + font-size: 1rem; + font-weight: 600; + letter-spacing: -0.01em; + color: var(--ink); + text-transform: none; +} + +.docs-provider > p { + margin: 0 0 0.5rem; +} + /* Inner pages (Contribute, Community) */ .page { padding: 2.75rem 0 4.5rem;