feat: improve prompt; update model list

This commit is contained in:
Simon
2026-02-09 15:50:20 +08:00
parent 851e9ef158
commit d00a8dcc21
15 changed files with 78 additions and 67 deletions

View File

@@ -40,7 +40,7 @@
```html
<script
src="https://registry.npmmirror.com/page-agent/1.1.0/files/dist/iife/page-agent.demo.js"
src="https://registry.npmmirror.com/page-agent/1.1.1/files/dist/iife/page-agent.demo.js"
crossorigin="true"
></script>
```
@@ -50,8 +50,8 @@
| Mirrors | URL |
| ------- | ---------------------------------------------------------------------------------- |
| Global | https://cdn.jsdelivr.net/npm/page-agent@1.1.0/dist/iife/page-agent.demo.js |
| China | https://registry.npmmirror.com/page-agent/1.1.0/files/dist/iife/page-agent.demo.js |
| Global | https://cdn.jsdelivr.net/npm/page-agent@1.1.1/dist/iife/page-agent.demo.js |
| China | https://registry.npmmirror.com/page-agent/1.1.1/files/dist/iife/page-agent.demo.js |
### NPM 安装

View File

@@ -40,7 +40,7 @@ Fastest way to try PageAgent with our free Demo LLM:
```html
<script
src="https://cdn.jsdelivr.net/npm/page-agent@1.1.0/dist/iife/page-agent.demo.js"
src="https://cdn.jsdelivr.net/npm/page-agent@1.1.1/dist/iife/page-agent.demo.js"
crossorigin="true"
></script>
```
@@ -50,8 +50,8 @@ Fastest way to try PageAgent with our free Demo LLM:
| Mirrors | URL |
| ------- | ---------------------------------------------------------------------------------- |
| Global | https://cdn.jsdelivr.net/npm/page-agent@1.1.0/dist/iife/page-agent.demo.js |
| China | https://registry.npmmirror.com/page-agent/1.1.0/files/dist/iife/page-agent.demo.js |
| Global | https://cdn.jsdelivr.net/npm/page-agent@1.1.1/dist/iife/page-agent.demo.js |
| China | https://registry.npmmirror.com/page-agent/1.1.1/files/dist/iife/page-agent.demo.js |
### NPM Installation

42
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{
"name": "root",
"version": "1.1.0",
"version": "1.1.1",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "root",
"version": "1.1.0",
"version": "1.1.1",
"license": "MIT",
"workspaces": [
"packages/page-controller",
@@ -1639,9 +1639,9 @@
}
},
"node_modules/@isaacs/brace-expansion": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/@isaacs/brace-expansion/-/brace-expansion-5.0.0.tgz",
"integrity": "sha512-ZT55BDLV0yv0RBm2czMiZ+SqCGO7AvmOM3G/w2xhVPH+te0aKgFjmBvGlL1dH+ql2tgGO3MVrbb3jCKyvpgnxA==",
"version": "5.0.1",
"resolved": "https://registry.npmjs.org/@isaacs/brace-expansion/-/brace-expansion-5.0.1.tgz",
"integrity": "sha512-WMz71T1JS624nWj2n2fnYAuPovhv7EUhk69R6i9dsVyzxt5eM3bjwvgk9L+APE1TRscGysAVMANkB0jh0LQZrQ==",
"dev": true,
"license": "MIT",
"dependencies": {
@@ -11049,11 +11049,11 @@
},
"packages/core": {
"name": "@page-agent/core",
"version": "1.1.0",
"version": "1.1.1",
"license": "MIT",
"dependencies": {
"@page-agent/llms": "1.1.0",
"@page-agent/page-controller": "1.1.0",
"@page-agent/llms": "1.1.1",
"@page-agent/page-controller": "1.1.1",
"chalk": "^5.6.2",
"zod": "^4.3.5"
}
@@ -11063,10 +11063,10 @@
"version": "0.1.3",
"hasInstallScript": true,
"dependencies": {
"@page-agent/core": "1.1.0",
"@page-agent/llms": "1.1.0",
"@page-agent/page-controller": "1.1.0",
"@page-agent/ui": "1.1.0",
"@page-agent/core": "1.1.1",
"@page-agent/llms": "1.1.1",
"@page-agent/page-controller": "1.1.1",
"@page-agent/ui": "1.1.1",
"@radix-ui/react-hover-card": "^1.1.15",
"@radix-ui/react-icons": "^1.3.2",
"@radix-ui/react-label": "^2.1.8",
@@ -11100,7 +11100,7 @@
},
"packages/llms": {
"name": "@page-agent/llms",
"version": "1.1.0",
"version": "1.1.1",
"license": "MIT",
"dependencies": {
"chalk": "^5.6.2",
@@ -11108,20 +11108,20 @@
}
},
"packages/page-agent": {
"version": "1.1.0",
"version": "1.1.1",
"license": "MIT",
"dependencies": {
"@page-agent/core": "1.1.0",
"@page-agent/llms": "1.1.0",
"@page-agent/page-controller": "1.1.0",
"@page-agent/ui": "1.1.0",
"@page-agent/core": "1.1.1",
"@page-agent/llms": "1.1.1",
"@page-agent/page-controller": "1.1.1",
"@page-agent/ui": "1.1.1",
"chalk": "^5.6.2",
"zod": "^4.3.5"
}
},
"packages/page-controller": {
"name": "@page-agent/page-controller",
"version": "1.1.0",
"version": "1.1.1",
"license": "MIT",
"dependencies": {
"ai-motion": "^0.4.8"
@@ -11129,12 +11129,12 @@
},
"packages/ui": {
"name": "@page-agent/ui",
"version": "1.1.0",
"version": "1.1.1",
"license": "MIT"
},
"packages/website": {
"name": "@page-agent/website",
"version": "1.1.0",
"version": "1.1.1",
"dependencies": {
"@radix-ui/react-icons": "^1.3.2",
"@radix-ui/react-separator": "^1.1.8",

View File

@@ -1,7 +1,7 @@
{
"name": "root",
"private": true,
"version": "1.1.0",
"version": "1.1.1",
"type": "module",
"workspaces": [
"packages/page-controller",

View File

@@ -1,7 +1,7 @@
{
"name": "@page-agent/core",
"private": false,
"version": "1.1.0",
"version": "1.1.1",
"type": "module",
"main": "./dist/esm/page-agent-core.js",
"module": "./dist/esm/page-agent-core.js",
@@ -45,7 +45,7 @@
"dependencies": {
"chalk": "^5.6.2",
"zod": "^4.3.5",
"@page-agent/llms": "1.1.0",
"@page-agent/page-controller": "1.1.0"
"@page-agent/llms": "1.1.1",
"@page-agent/page-controller": "1.1.1"
}
}

View File

@@ -144,12 +144,12 @@ Here are examples of good output patterns. Use them as reference but never copy
</examples>
<output>
You must ALWAYS respond with a valid JSON in this exact format:
{
"evaluation_previous_goal": "Concise one-sentence analysis of your last action. Clearly state success, failure, or uncertain.",
"memory": "1-3 concise sentences of specific memory of this step and overall progress. You should put here everything that will help you track progress in future steps. Like counting pages visited, items found, etc.",
"next_goal": "State the next immediate goal and action to achieve it, in one clear sentence."
"action":{"action": {// action-specific parameter}}
"next_goal": "State the next immediate goal and action to achieve it, in one clear sentence.",
"action":{
"Action name": {// Action parameters}
}
}
</output>

View File

@@ -23,10 +23,10 @@
"wxt": "^0.20.13"
},
"dependencies": {
"@page-agent/core": "1.1.0",
"@page-agent/llms": "1.1.0",
"@page-agent/page-controller": "1.1.0",
"@page-agent/ui": "1.1.0",
"@page-agent/core": "1.1.1",
"@page-agent/llms": "1.1.1",
"@page-agent/page-controller": "1.1.1",
"@page-agent/ui": "1.1.1",
"@radix-ui/react-hover-card": "^1.1.15",
"@radix-ui/react-icons": "^1.3.2",
"@radix-ui/react-label": "^2.1.8",

View File

@@ -136,12 +136,12 @@ Here are examples of good output patterns. Use them as reference but never copy
</examples>
<output>
You must ALWAYS respond with a valid JSON in this exact format:
{
"evaluation_previous_goal": "Concise one-sentence analysis of your last action. Clearly state success, failure, or uncertain.",
"memory": "1-3 concise sentences of specific memory of this step and overall progress. You should put here everything that will help you track progress in future steps. Like counting pages visited, items found, etc.",
"next_goal": "State the next immediate goal and action to achieve it, in one clear sentence."
"action":{"action_name": {// action-specific parameter}}
"next_goal": "State the next immediate goal and action to achieve it, in one clear sentence.",
"action":{
"Action name": {// Action parameters}
}
}
</output>

View File

@@ -1,6 +1,6 @@
{
"name": "@page-agent/llms",
"version": "1.1.0",
"version": "1.1.1",
"type": "module",
"main": "./dist/lib/page-agent-llms.js",
"module": "./dist/lib/page-agent-llms.js",

View File

@@ -1,7 +1,7 @@
{
"name": "page-agent",
"private": false,
"version": "1.1.0",
"version": "1.1.1",
"type": "module",
"main": "./dist/esm/page-agent.js",
"module": "./dist/esm/page-agent.js",
@@ -46,9 +46,9 @@
"dependencies": {
"chalk": "^5.6.2",
"zod": "^4.3.5",
"@page-agent/llms": "1.1.0",
"@page-agent/page-controller": "1.1.0",
"@page-agent/core": "1.1.0",
"@page-agent/ui": "1.1.0"
"@page-agent/llms": "1.1.1",
"@page-agent/page-controller": "1.1.1",
"@page-agent/core": "1.1.1",
"@page-agent/ui": "1.1.1"
}
}

View File

@@ -1,6 +1,6 @@
{
"name": "@page-agent/page-controller",
"version": "1.1.0",
"version": "1.1.1",
"type": "module",
"main": "./dist/lib/page-controller.js",
"module": "./dist/lib/page-controller.js",

View File

@@ -1,6 +1,6 @@
{
"name": "@page-agent/ui",
"version": "1.1.0",
"version": "1.1.1",
"type": "module",
"main": "./dist/lib/page-agent-ui.js",
"module": "./dist/lib/page-agent-ui.js",

View File

@@ -1,7 +1,7 @@
{
"name": "@page-agent/website",
"private": true,
"version": "1.1.0",
"version": "1.1.1",
"type": "module",
"scripts": {
"dev": "vite --host 0.0.0.0",

View File

@@ -1,8 +1,8 @@
// Demo build (auto-init with demo LLM, for quick testing)
export const CDN_DEMO_URL =
'https://cdn.jsdelivr.net/npm/page-agent@1.1.0/dist/iife/page-agent.demo.js'
'https://cdn.jsdelivr.net/npm/page-agent@1.1.1/dist/iife/page-agent.demo.js'
export const CDN_DEMO_CN_URL =
'https://registry.npmmirror.com/page-agent/1.1.0/files/dist/iife/page-agent.demo.js'
'https://registry.npmmirror.com/page-agent/1.1.1/files/dist/iife/page-agent.demo.js'
// Demo LLM for website testing
export const DEMO_MODEL = 'PAGE-AGENT-FREE-TESTING-RANDOM'

View File

@@ -1,3 +1,5 @@
import { Fragment } from 'react'
import CodeEditor from '@/components/CodeEditor'
import { useLanguage } from '@/i18n/context'
@@ -6,22 +8,30 @@ const BASELINE = new Set([
'claude-haiku-4.5',
'gemini-3-flash',
'deepseek-3.2',
'qwen-3-max',
'qwen3-coder-next',
])
// Models grouped by brand, newest first
const MODEL_GROUPS: Record<string, string[]> = {
OpenAI: ['gpt-5.2', 'gpt-5.1', 'gpt-5', 'gpt-5-mini', 'gpt-4.1', 'gpt-4.1-mini'],
Anthropic: ['claude-opus-4.5', 'claude-sonnet-4.5', 'claude-haiku-4.5', 'claude-sonnet-3.5'],
Google: ['gemini-3-pro', 'gemini-3-flash', 'gemini-2.5'],
Qwen: ['qwen-3-max', 'qwen-3-plus', 'qwen3:14b (ollama)'],
Qwen: ['qwen3-coder-next', 'qwen-3-max', 'qwen-3-plus', 'qwen3:14b (ollama)'],
DeepSeek: ['deepseek-3.2'],
xAI: ['grok-4', 'grok-code-fast'],
Anthropic: [
'claude-opus-4.6',
'claude-opus-4.5',
'claude-sonnet-4.5',
'claude-haiku-4.5',
'claude-sonnet-3.5',
],
xAI: ['grok-4.1-fast', 'grok-4', 'grok-code-fast'],
MoonshotAI: ['kimi-k2.5'],
'Z.AI': ['glm-4.7'],
}
const ModelBadge = ({ model, baseline }: { model: string; baseline?: boolean }) => (
<div
className={`px-3 py-1.5 rounded-md text-sm font-medium font-mono transition-colors ${
className={`px-3 py-1.5 rounded-md text-xs font-medium font-mono transition-colors ${
baseline
? 'bg-emerald-500 text-white shadow-sm'
: 'bg-white/80 dark:bg-gray-800/80 text-gray-800 dark:text-gray-200 border border-gray-300 dark:border-gray-600'
@@ -53,19 +63,20 @@ export default function Models() {
: 'Recommended: Fast, lightweight models with strong ToolCall capabilities.'}
</p>
<div className="bg-linear-to-br from-emerald-50 to-cyan-50 dark:from-emerald-950/30 dark:to-cyan-950/30 rounded-xl p-6 border border-emerald-200/50 dark:border-emerald-800/50">
<div className="space-y-3">
<div className="grid grid-cols-[5rem_1fr] gap-x-3 gap-y-3 items-start">
{Object.entries(MODEL_GROUPS).map(([brand, models]) => (
<div key={brand} className="flex flex-wrap items-center gap-2">
<span className="text-xs font-semibold text-gray-500 dark:text-gray-400 w-20 shrink-0">
<Fragment key={brand}>
<span className="text-xs font-semibold text-gray-500 dark:text-gray-400 pt-2">
{brand}
</span>
<div className="flex flex-wrap gap-2">
{models.map((model) => (
<ModelBadge key={model} model={model} baseline={BASELINE.has(model)} />
))}
</div>
</Fragment>
))}
</div>
<p className="text-xs text-gray-600 dark:text-gray-400 mt-5"> baseline models</p>
</div>
</section>