- config: ModelInfo.params + MODEL_PARAM_KEYS 白名单 + _parse_model_params(写错即 ConfigError) - adapters: _forced_params 在 payload 组装后强制覆盖;_learn_from_upstream_error 按上游 400 要求修正并重发一次(非原样重试);流式已吐内容则不重发 - main: /v1/models 暴露 params;探针超时 15s→30s;_speedtest_error_text 说清超时/上游原文 - settings: 面板保存保留手写 models[].params(原先会被静默清掉) - gateway.yaml: kimi-k2.7-code params.temperature=1 - 前端: Models 挂锁+参数固定标签;Chat 温度 chip 挂锁+抽屉提示;新增 lock 图标;中英对称 - tests: +10 → 168 passed / 0 failed
785 lines
33 KiB
TypeScript
785 lines
33 KiB
TypeScript
// English locale resource
|
||
export default {
|
||
nav: {
|
||
title: 'API Gateway',
|
||
connected: 'Connected to api.wangjinding.com',
|
||
disconnected: 'Connection error',
|
||
menudashboard: 'Dashboard',
|
||
menuchat: 'Chat',
|
||
menuimages: 'Images',
|
||
menuvideos: 'Videos',
|
||
menumodels: 'Models & Providers',
|
||
menumetrics: 'Metrics',
|
||
menukeys: 'API Keys',
|
||
menuusers: 'Users',
|
||
menulogs: 'Logs',
|
||
menufeedback: 'Feedback',
|
||
menufeedbackinbox: 'User feedback',
|
||
menusettings: 'Settings',
|
||
control: 'Console',
|
||
more: 'More',
|
||
subdashboard: 'Gateway overview · refreshed every 8s',
|
||
subchat: 'Vision-ready · route wjd picks the fastest provider',
|
||
subimages: 'Params on the left, history on the right · downloads proxied by the gateway',
|
||
subvideos: '720P · 4–12s · async polling',
|
||
submodels: 'Providers / models / route chains',
|
||
submetrics: 'Usage & cost · isolated per account',
|
||
subkeys: 'Up to 3 per account · stored in plaintext, copyable anytime',
|
||
subusers: 'Accounts & roles · admin can inspect others’ logs and assets',
|
||
sublogs: 'Isolated per account · expand for request / response details',
|
||
subfeedback: 'Something off? Tell us · images welcome',
|
||
subfeedbackinbox: 'Feedback from every account · images included',
|
||
subgatewaycfg: 'Every config key, editable · applied on save',
|
||
menugatewaycfg: 'Gateway config',
|
||
subsettings: 'Appearance / generation defaults / security / gateway',
|
||
},
|
||
theme: {
|
||
choose: 'Appearance',
|
||
followSystem: 'Follow system dark mode',
|
||
followShort: 'System',
|
||
applied: 'Theme switched',
|
||
// Skin names / blurbs (mirror of zh.ts)
|
||
nameA: 'A · Deep Space Blue',
|
||
descA: 'Dark base + teal, easy on the eyes at night',
|
||
nameB: 'B · Ivory Indigo',
|
||
descB: 'Light base with white cards, clearest in daylight',
|
||
nameC: 'C · Warm Sand Green',
|
||
descC: 'Warm off-white + deep green, calm and steady',
|
||
},
|
||
top: {
|
||
refresh: 'Refresh this page',
|
||
},
|
||
common: {
|
||
all: 'All',
|
||
export: 'Export',
|
||
refresh: 'Refresh',
|
||
admin: 'admin',
|
||
logout: 'Sign out',
|
||
yes: 'Yes',
|
||
no: 'No',
|
||
none: '—',
|
||
empty: '(empty)',
|
||
ok: 'OK',
|
||
fail: 'FAIL',
|
||
copy: 'Copy',
|
||
copyOk: 'Copied',
|
||
copyFail: 'Copy failed — select the text manually',
|
||
save: 'Save',
|
||
delete: 'Delete',
|
||
reset: 'Reset',
|
||
search: 'Search',
|
||
confirm: 'Confirm',
|
||
cancel: 'Cancel',
|
||
},
|
||
login: {
|
||
title: 'API Gateway Console',
|
||
userPlaceholder: 'Username',
|
||
passPlaceholder: 'Password',
|
||
btn: 'Sign in',
|
||
errEmpty: 'Please enter account and password',
|
||
err401: 'Incorrect username or password',
|
||
err429: 'Too many attempts, rate-limited. Please try again later',
|
||
err403: 'Sign-in denied (account disabled or invalid role)',
|
||
errConn: 'Cannot reach gateway — is it running on 8808?',
|
||
success: 'Signed in',
|
||
},
|
||
dashboard: {
|
||
modelCount: 'Models',
|
||
providers: 'Providers',
|
||
routes: 'Route aliases',
|
||
fallback: 'Fallbacks',
|
||
inflight: 'In-flight',
|
||
callsMix: 'Calls ok/fail',
|
||
provShare: 'Provider success share',
|
||
latency: 'Model latency P50 / P95 (s)',
|
||
providerStatus: 'Provider status',
|
||
mediaCircuit: 'Media circuit',
|
||
circuit: 'Circuit',
|
||
modelCountShort: 'Models',
|
||
keySet: 'Key set',
|
||
routeAlias: 'Route aliases',
|
||
name: 'Name',
|
||
modelChain: 'Model chain',
|
||
gatewayInfo: 'Gateway info',
|
||
running: 'Running',
|
||
uptime: 'Uptime',
|
||
gwVersion: 'Gateway version',
|
||
concurrency: 'In-flight {cur} / peak {peak}',
|
||
latTitle: 'Model latency P50 / P95 (s)',
|
||
circ_closed: 'CLOSED',
|
||
circ_half_open: 'HALF_OPEN',
|
||
circ_open: 'OPEN',
|
||
circ_not_tracked: 'Not tracked',
|
||
noData: 'No data',
|
||
requests: 'Total requests',
|
||
successRate: 'Success rate',
|
||
avgLatency: 'Avg latency',
|
||
fallbackShort: 'Fallbacks',
|
||
noteOkFail: 'ok {ok} · fail {fail}',
|
||
noteFail: '{n} failed',
|
||
noteP95: 'highest P95 {v}s',
|
||
noteInflight: '{n} in flight',
|
||
modelCalls: 'Calls by model',
|
||
colModel: 'Model',
|
||
colCalls: 'Calls',
|
||
colLatency: 'Avg latency',
|
||
colRate: 'Success rate',
|
||
noModels: 'No calls recorded yet',
|
||
share: 'Share',
|
||
live: 'Live',
|
||
routeChain: 'Availability + speed first',
|
||
},
|
||
metrics: {
|
||
uptime: 'Uptime',
|
||
inflight: 'In-flight/peak',
|
||
fallback: 'Fallbacks',
|
||
promptTokens: 'Prompt tokens',
|
||
completionTokens: 'Completion tokens',
|
||
callsTotal: 'Total calls (ok/fail)',
|
||
modelCalls: 'Calls per model (success / fail)',
|
||
provShare: 'Provider success share',
|
||
routeVsProvider: 'Route vs provider (success / fail / fallback)',
|
||
latency: 'Model latency P50 / P95 (s)',
|
||
success: 'Success',
|
||
fail: 'Fail',
|
||
fallback2: 'Fallback',
|
||
ok: 'ok',
|
||
none: 'None',
|
||
circuitStatus: 'Circuit breaker status',
|
||
provider: 'Provider',
|
||
state: 'State',
|
||
recentFailures: 'Recent failures',
|
||
window: 'Window',
|
||
threshold: 'Threshold',
|
||
cooldown: 'Cooldown(s)',
|
||
probing: 'Probing',
|
||
stateClosed: 'CLOSED',
|
||
stateHalf: 'HALF_OPEN',
|
||
stateOpen: 'OPEN',
|
||
loadErr: 'Failed to load metrics',
|
||
requests: 'Total requests',
|
||
failCount: 'Failures',
|
||
tokenUsage: 'Token usage',
|
||
tokenNote: 'in {p} / out {c}',
|
||
inflightPeak: 'In flight / peak',
|
||
failRateNote: 'failure rate {v}%',
|
||
snapshot: 'Live snapshot',
|
||
circuitCard: 'Circuit breakers',
|
||
},
|
||
logs: {
|
||
all: 'All',
|
||
chat: 'Chat',
|
||
image: 'Image',
|
||
video: 'Video',
|
||
autoRefresh: 'Auto-refresh',
|
||
method: 'Method',
|
||
result: 'Result',
|
||
success: 'Success',
|
||
fail: 'Fail',
|
||
searchPlaceholder: 'Search model/provider/path/request/response',
|
||
count: '{n} entries',
|
||
clearFilter: 'Clear filter',
|
||
time: 'Time',
|
||
path: 'Path',
|
||
modelProvider: 'Model / provider',
|
||
reqContent: 'Request',
|
||
respContent: 'Response',
|
||
empty: 'No logs',
|
||
emptyFiltered: 'No entries match the current filters ({n} loaded — clear other filters or the keyword)',
|
||
media: 'Download',
|
||
request: 'Request',
|
||
polls: 'Polls ({n})',
|
||
response: 'Response',
|
||
error: 'Error',
|
||
rid: 'rid',
|
||
caller: 'Caller',
|
||
reqModel: 'Requested model',
|
||
served: 'Served model',
|
||
provider: 'Provider',
|
||
streaming: 'Streaming',
|
||
loadErr: 'Failed to load logs',
|
||
},
|
||
users: {
|
||
viewLogs: 'View logs',
|
||
viewActivity: 'Activity',
|
||
tabLogs: 'Call logs',
|
||
tabImages: 'Images',
|
||
tabVideos: 'Videos',
|
||
noData: 'No records',
|
||
// Admin downloads this account's generated images / videos (proxied by the gateway)
|
||
dl: 'Download',
|
||
dlOk: 'Download started',
|
||
dlFail: 'Download failed: {msg}',
|
||
dlNoSrc: 'This record has no downloadable URL yet',
|
||
},
|
||
chat: {
|
||
newChat: 'New chat',
|
||
session: 'Conversation',
|
||
thisConv: 'This conversation',
|
||
model: 'Model',
|
||
elapsed: 'Elapsed',
|
||
msgsN: '{n} msgs',
|
||
regenerate: 'Regenerate',
|
||
copyAll: 'Copy all',
|
||
tempShort: 'Temp',
|
||
maxShort: 'Max',
|
||
systemShort: 'System',
|
||
visionReady: 'Vision ready · images supported',
|
||
visionOff: 'This model does not accept images',
|
||
chainLabel: '{id} ({chain})',
|
||
emptyChain: 'empty',
|
||
phDefault: 'Default',
|
||
phOptional: 'Optional',
|
||
totalTokens: 'Total {n}',
|
||
uploadedImage: 'Uploaded image',
|
||
reasoningTag: 'Reasoning',
|
||
routeGroup: 'Routes (auto fallback)',
|
||
textModels: 'Text models',
|
||
params: 'Parameters',
|
||
clear: 'Clear',
|
||
generating: 'Generating…',
|
||
empty: 'Start a conversation with the gateway (any text model or route wjd)',
|
||
fallback: 'Fallback · by {provider}',
|
||
servedBy: 'by {provider}',
|
||
requestedTo: 'requested {req} → served {served}',
|
||
reasoning: 'Reasoning',
|
||
thinking: 'Thinking…',
|
||
emptyResp: '(empty response)',
|
||
youError: 'Error: {msg}',
|
||
placeholder: 'Type a message, Enter to send, Shift+Enter for newline',
|
||
imgUpload: 'Upload image',
|
||
imgUrlBtn: 'Image URL',
|
||
imgPh: 'Paste an image URL, Enter to add',
|
||
imgAdd: 'Add',
|
||
imgMax: 'At most {n} images per message',
|
||
imgPickErr: 'Image processing failed: {msg}',
|
||
visionWarn: 'Model {model} does not accept image input — images will be ignored or rejected. Switch to a vision-capable model.',
|
||
paramLocked: 'Parameters pinned by the gateway: {p} (upstream hard limit; what you set here is overridden before sending)',
|
||
useVision: 'Switch to {model}',
|
||
waiting: 'Awaiting input…',
|
||
send: 'Send',
|
||
stop: 'Stop',
|
||
stopped: 'Stopped',
|
||
temp: 'Temperature',
|
||
topP: 'top_p',
|
||
maxTokens: 'max_tokens (empty = default)',
|
||
streaming: 'Streaming output',
|
||
system: 'System prompt (prepended to each conversation)',
|
||
loadModelsErr: 'Failed to load models: {msg}',
|
||
},
|
||
images: {
|
||
historyTitle: 'History',
|
||
historySub: '{n} images',
|
||
refsLabel: 'Reference images',
|
||
title: 'Image generation',
|
||
model: 'Image model',
|
||
size: 'Size',
|
||
ratio: 'Ratio',
|
||
refsUpload: 'Upload reference',
|
||
refsUrlBtn: 'Reference URL',
|
||
refsHint: '(empty = text-to-image; uploaded images are compressed in-browser, uploads and URLs can be mixed)',
|
||
refsMax: 'At most {n} reference images',
|
||
refPickErr: 'Image processing failed: {msg}',
|
||
refsPH: 'Image-to-image / multi-image: image URLs or data:, one per line (empty = text-to-image)',
|
||
count: 'Count',
|
||
countTip: 'The upstream API returns 1 image per call; multiple images are generated one by one',
|
||
genProgress: 'Generating {i}/{n}',
|
||
partialFail: 'Generated {done}, image #{i} failed: {msg}',
|
||
refsUsed: '{n} reference image(s)',
|
||
emptyResp: 'The upstream returned no image',
|
||
placeholder: 'Describe the image to generate (style / subject / composition)',
|
||
servedBy: 'Generated by {provider}',
|
||
clear: 'Clear history',
|
||
confirmClear: 'Clear all {n} image record(s)? They are also deleted server-side (other devices lose them too). This cannot be undone.',
|
||
generate: 'Generate',
|
||
promptRow: 'Prompt',
|
||
imgLoadErr: 'Image failed to load',
|
||
dl: 'Download',
|
||
dlOk: 'Download started',
|
||
dlFail: 'Download failed: {msg}',
|
||
dlNoSrc: 'This image has no downloadable URL',
|
||
empty: 'Generated images appear here',
|
||
loadErr: 'Failed to generate image',
|
||
},
|
||
videos: {
|
||
taskTitle: 'Tasks',
|
||
fixed: 'Fixed',
|
||
title: 'Video generation',
|
||
model: 'Video model',
|
||
mode: 'Scenario',
|
||
modeText: 'Text to video',
|
||
modeKeyframe: 'Keyframe (img2video)',
|
||
modeReference: 'Reference img/audio',
|
||
firstFrame: 'First frame',
|
||
lastFrame: 'Last frame',
|
||
upload: 'Upload image',
|
||
uploadImg: 'Upload reference',
|
||
uploadAudio: 'Upload audio',
|
||
useUrl: 'Use URL',
|
||
urlPH: 'or paste an image URL',
|
||
uploadTip: 'Uploaded material is compressed to a data URI in the browser and sent directly (no public URL needed)',
|
||
pickErr: 'Failed to process material: {msg}',
|
||
refMax: 'At most {n} reference images',
|
||
audMax: 'At most {n} reference audios',
|
||
count5: '{n}/5 selected',
|
||
count3: '{n}/3 selected',
|
||
media: 'Media',
|
||
seed: 'Seed',
|
||
seedPH: 'empty = random',
|
||
keyframeTip: 'Give at least one of first/last frame — upload or paste a URL (first = opening shot, last = closing shot)',
|
||
refImagesPH: 'Reference image URLs, one per line (max 5)',
|
||
refAudiosPH: 'Reference audio URLs, one per line (max 3)',
|
||
referenceTip: 'In the prompt, <Picture N> / <Audio N> refer to the Nth material',
|
||
placeholderRef: 'Describe the video and camera move (use <Picture 1> / <Audio 1> for reference materials)',
|
||
needFrame: 'Keyframe mode needs at least one uploaded image or image URL',
|
||
needRef: 'Reference mode needs at least one image or audio (upload or URL)',
|
||
duration: 'Duration (s)',
|
||
aspect: 'Aspect',
|
||
quality: 'Quality',
|
||
placeholder: 'Describe the video content and camera movement',
|
||
async: 'Submit async (return now, poll later)',
|
||
taskCount: 'Tasks {n}',
|
||
clear: 'Clear finished',
|
||
confirmClear: 'Clear {n} finished video task(s)? Records and video links are also deleted server-side. This cannot be undone.',
|
||
generate: 'Generate video',
|
||
status: 'Status',
|
||
task: 'Task',
|
||
service: 'Service',
|
||
promptRow: 'Prompt',
|
||
elapsed: 'Elapsed',
|
||
subElapsed: '{n}s elapsed',
|
||
subWait: 'waiting {n}s',
|
||
raw: 'Raw response',
|
||
empty: 'Submitted video tasks appear here',
|
||
failText: 'Generation failed',
|
||
doneText: 'Done',
|
||
doingText: 'Generating…',
|
||
doneMsg: 'Video ready',
|
||
dl: 'Download video',
|
||
dlOk: 'Download started',
|
||
dlFail: 'Download failed: {msg}',
|
||
dlNoSrc: 'This task has no downloadable video yet',
|
||
submitMsg: 'Submitted task {id}',
|
||
loadErr: 'Failed to load videos',
|
||
},
|
||
models: {
|
||
routeAliasTitle: 'Route aliases (auto fallback chain)',
|
||
modelListTitle: 'Model list',
|
||
name: 'Name',
|
||
chainLabel: 'Model chain (tried in order, auto fallback on failure)',
|
||
providerCount: 'Providers',
|
||
id: 'Model ID',
|
||
type: 'Type',
|
||
provider: 'Provider',
|
||
keySet: 'Key set',
|
||
text: 'Text',
|
||
image: 'Image',
|
||
video: 'Video',
|
||
route: 'Route',
|
||
model: 'Models',
|
||
textModels: 'Text models',
|
||
imageModels: 'Image models',
|
||
videoModels: 'Video models',
|
||
routes: 'Route aliases',
|
||
providers: 'Providers',
|
||
loadErr: 'Failed to load models',
|
||
capability: 'Capability',
|
||
visionTag: 'Vision',
|
||
paramTag: 'Params locked',
|
||
paramLocked: 'Parameters pinned by the gateway: {p} (upstream hard limit; values from clients and the speed test are overridden)',
|
||
allTextModels: 'All text models',
|
||
providerCard: 'Providers',
|
||
keyOk: 'Key configured',
|
||
keyMissing: 'Key missing',
|
||
routeCount: '{n} routes',
|
||
chainCount: '{n} models',
|
||
providerCount2: '{n} providers',
|
||
noRoute: 'No route alias configured',
|
||
speedtest: 'Test speed',
|
||
testing: 'Probing latency of every text model…',
|
||
testingShort: 'Testing…',
|
||
testOne: 'Test this model',
|
||
latency: 'Latency',
|
||
failed: 'Failed',
|
||
speedtestDone: 'Speed test done, {n} models',
|
||
speedtestFail: 'Speed test failed',
|
||
},
|
||
history: {
|
||
saveFail: 'History could not be saved to the gateway (it may be lost on refresh) — check your session or network',
|
||
offline: 'History API unreachable — showing local browser cache only',
|
||
},
|
||
settings: {
|
||
keyUnlimited: 'Unlimited',
|
||
connInfo: 'Connection',
|
||
gwAddress: 'Gateway URL',
|
||
gwVersion: 'Gateway version',
|
||
loginUser: 'User',
|
||
sessionLen: 'Session duration',
|
||
hours: '{n} hours',
|
||
language: 'Language',
|
||
langTip: 'Switch interface language (saved locally)',
|
||
theme: 'Appearance',
|
||
appearance: 'Appearance & language',
|
||
themeSub: 'B is the default; switch to A / C anytime',
|
||
current: 'Current',
|
||
switch: 'Switch',
|
||
followSystem: 'Follow system dark mode',
|
||
followSub: 'Use theme A automatically when the system goes dark',
|
||
langSub: 'Full Chinese / English coverage',
|
||
myKeys: 'My API keys',
|
||
myKeysSub: 'Create / copy / delete, up to 3 per account',
|
||
manage: 'Manage',
|
||
gwCard: 'Gateway info',
|
||
account: 'Account',
|
||
logoutTip: 'Signing out ends this session; log in again with account and password.',
|
||
logoutBtn: 'Sign out',
|
||
chatDefaults: 'Chat default parameters',
|
||
defsTip: 'Used as defaults for a new chat (already-adjusted params are untouched).',
|
||
defaultModel: 'Default model / route',
|
||
temperature: 'Temperature',
|
||
topP: 'top_p',
|
||
maxTokens: 'max_tokens (empty = gateway default)',
|
||
streaming: 'Streaming output',
|
||
system: 'System prompt',
|
||
save: 'Save defaults',
|
||
saveOk: 'Defaults saved — applied to new chats',
|
||
resetOk: 'Restored to defaults',
|
||
providerStatus: 'Provider status',
|
||
modelsCount: 'Models',
|
||
userManagement: 'Account management (admin)',
|
||
gwConfigBtn: 'Open',
|
||
gwConfigSub: 'Tune gateway / providers / routes / pricing — applied on save',
|
||
gwConfig: 'Gateway config (admin)',
|
||
userCol: 'User',
|
||
roleCol: 'Role',
|
||
accountDeleted: 'Account {name} deleted (sessions and API keys revoked)',
|
||
revokeKeys: 'Revoke all keys',
|
||
revokeKeysOk: 'Revoked {n} API key(s) of {name}',
|
||
resetPwOk: 'Password of {name} reset to the username; {n} session(s) kicked out',
|
||
confirmDeleteUser: 'Delete account {name}? Its sessions and API keys stop working immediately. This cannot be undone.',
|
||
confirmResetPw: 'Reset the password of {name} to its username? Active sessions of that account will be signed out.',
|
||
confirmRevokeKeys: 'Revoke every API key of {name}? Callers must create new keys to keep using the gateway.',
|
||
userPwOptional: 'Initial password (empty = same as username)',
|
||
confirm: 'Confirm',
|
||
confirmDeleteKey: 'Delete this API key? Clients using it get 401 immediately and need a new key.',
|
||
usersTip: 'Create accounts / reset passwords / disable or enable / delete (admin only)',
|
||
userCreated: 'Created',
|
||
// Round 24: admin can disable / enable an account
|
||
userDisabled: 'Disabled',
|
||
userDisabledAt: 'Disabled at {ts}',
|
||
disableUser: 'Disable',
|
||
enableUser: 'Enable',
|
||
confirmDisableUser: 'Disable account {name}? It can no longer sign in, its API keys stop working immediately (keys are kept and work again once re-enabled), and its signed-in sessions are kicked out.',
|
||
userDisabledOk: 'Account {name} disabled ({n} session(s) kicked out, API keys suspended)',
|
||
userEnabledOk: 'Account {name} enabled — old password and API keys work again',
|
||
namesRule: 'Username must be alphanumeric; default password = username',
|
||
changePw: 'Change password',
|
||
newPw: 'New password (min 4 chars)',
|
||
pwTip: 'You are signed in — just set a new password, no current password needed. All sessions are revoked and you will sign in again with the new one.',
|
||
pwNeedNew: 'Please enter a new password',
|
||
pwChanged: 'Password updated — please sign in again',
|
||
keyLabel: 'Label (optional)',
|
||
keyHint: 'Key prefix',
|
||
keyCreated: 'Created',
|
||
createKey: 'Create API Key',
|
||
keyCol: 'API key',
|
||
keyLimitFull: 'Limit reached',
|
||
keyLegacyNoEcho: '(created before plaintext echo — cannot be shown again)',
|
||
noKey: 'You have no API Key — create one to use as a Bearer credential externally',
|
||
userMgmt: 'Account management (admin)',
|
||
newUserName: 'New username (alphanumeric)',
|
||
newUserTip: 'Create account; default password = username',
|
||
createUser: 'Create account',
|
||
keyCount: 'Keys',
|
||
resetPw: 'Reset password',
|
||
loadErr: 'Failed to load settings',
|
||
},
|
||
apidoc: {
|
||
copyCurl: 'Copy curl example',
|
||
viewDoc: 'View API docs',
|
||
title: 'API usage guide',
|
||
intro: 'Use the API Key above as the Bearer credential to call the gateway (OpenAI compatible). API keys can only call models; creating keys / changing passwords / managing accounts require a web session — a key hitting admin endpoints gets 403.',
|
||
baseTitle: 'Basics',
|
||
baseUrl: 'Base URL',
|
||
auth: 'Auth',
|
||
authVal: 'Header: Authorization: Bearer <your API Key>',
|
||
modelPick: 'Model selection',
|
||
modelPickVal: 'model: wjd = route alias (auto-fallback by availability + speed, recommended); or a concrete model id to bypass fallback',
|
||
ctype: 'Request format',
|
||
ctypeVal: 'application/json; chat supports SSE streaming (stream: true)',
|
||
endpoints: 'Endpoints',
|
||
colMethod: 'Method',
|
||
colPath: 'Path',
|
||
colDesc: 'Description',
|
||
epModels: 'Models and routes (with a vision flag)',
|
||
epChat: 'Chat completions (OpenAI compatible, streaming + image input)',
|
||
epImages: 'Image generation / image-to-image (n must be 1; call repeatedly for more)',
|
||
epVideoCreate: 'Video generation (async, returns video_id immediately)',
|
||
epVideoPoll: 'Poll a video task (every ~5s; returns throttled when upstream rate-limits)',
|
||
epHistory: 'Read your own history (images / videos / chats)',
|
||
epLogs: 'Your own call log',
|
||
epMetrics: 'Metrics snapshot (incl. circuit breaker states)',
|
||
epHealth: 'Health check (version / provider status)',
|
||
exChat: 'Example · chat',
|
||
exImg: 'Example · image generation',
|
||
exVideo: 'Example · video generation + polling',
|
||
exPy: 'Example · Python (OpenAI SDK compatible)',
|
||
// Comments / sample payloads inside the code samples (mirror of zh.ts)
|
||
sampleChat: 'Hello, introduce yourself',
|
||
sampleImg: 'Neon city street at night',
|
||
sampleVideo: 'Slow camera push-in',
|
||
sampleStep1: 'submit a task (async, returns video_id immediately)',
|
||
sampleStep2: 'poll every 5s (a throttled reply means wait, then retry)',
|
||
notes: 'Notes',
|
||
noteVision: 'For image input use a vision model (agnes-3.0-flash, marked "Vision" in the list); with the wjd alias the gateway puts vision models first.',
|
||
noteN1: 'Image n must be 1 (upstream limit) — call once per image; n≠1 is rejected with a clean 400.',
|
||
noteVideo: 'Video seconds: 4–12 only; size is fixed at 720P; 6 aspect ratios (21:9/16:9/4:3/1:1/3:4/9:16); mode=text / keyframe / reference.',
|
||
notePoll: 'Do not poll faster than 5s (upstream answers 429 "too frequent"; the gateway returns throttled so you can back off).',
|
||
noteMedia: 'Assets (reference images / first-last frames / audio / chat images) accept data:image/...;base64,... or a public URL; data URIs avoid exposing the file, but keep each request body under 2MB.',
|
||
noteKey: 'If a key leaks, delete it here (401 immediately) or revoke all keys of the account from the Users page.',
|
||
noteAudit: 'Every call is logged per account on the Logs page (you see yours; admins can inspect each account from the Users page).',
|
||
copyBase: 'Copy URL',
|
||
copyCmd: 'Copy',
|
||
},
|
||
// Round 22: feedback (member submit + progress) / inbox (admin: all + update progress)
|
||
fbStatus: {
|
||
pending: 'Pending',
|
||
doing: 'In progress',
|
||
done: 'Resolved',
|
||
},
|
||
feedback: {
|
||
write: 'Write your feedback',
|
||
placeholder: 'What feels clunky, what feature you want, what is unclear — anything goes',
|
||
attach: 'Add image',
|
||
imagesHint: 'Up to {n} · compressed before upload',
|
||
remove: 'Remove',
|
||
needContent: 'Write something before submitting',
|
||
submit: 'Submit',
|
||
submitted: 'Got it — thanks for the feedback!',
|
||
mine: 'My submissions',
|
||
mineSub: 'Track progress here after submitting',
|
||
empty: 'No feedback submitted yet',
|
||
statusAll: 'All statuses',
|
||
|
||
revoke: 'Withdraw',
|
||
revokeTitle: 'Withdraw this feedback?',
|
||
revokeBody: 'Withdrawing deletes "{n}" permanently — once an admin starts handling it you can no longer withdraw.',
|
||
revoked: 'Withdrawn',
|
||
},
|
||
// Handling log (timeline): submission + every admin action
|
||
fbLog: {
|
||
title: 'Handling log',
|
||
submitted: 'submitted',
|
||
more: 'Show all {n} entries',
|
||
less: 'Collapse',
|
||
},
|
||
inbox: {
|
||
all: 'All accounts',
|
||
allStatus: 'All statuses',
|
||
kw: 'Search content / account',
|
||
empty: 'No feedback yet',
|
||
emptyFiltered: 'Loaded {n} items, none match the current filter',
|
||
count: '{n} total',
|
||
account: 'Account',
|
||
status: 'Status',
|
||
handle: 'Update',
|
||
archAll: 'All',
|
||
archActive: 'Active only',
|
||
archOnly: 'Archived only',
|
||
archived: 'Archived',
|
||
archive: 'Archive',
|
||
unarchive: 'Unarchive',
|
||
delete: 'Delete',
|
||
deleteConfirm: 'Permanently delete this feedback and all its images — cannot be undone. Delete?',
|
||
deleted: 'Deleted',
|
||
archOk: 'Archived',
|
||
unarchOk: 'Unarchived',
|
||
|
||
dialogTitle: 'Update this feedback',
|
||
noteLabel: 'Note (visible to the submitter)',
|
||
notePlaceholder: 'e.g. Reproduced the export button, shipping next release',
|
||
save: 'Save',
|
||
saved: 'Progress updated',
|
||
preview: 'View full size',
|
||
noPreview: 'No preview — click to load the original',
|
||
loading: 'Loading…',
|
||
loadFail: 'Failed to load image',
|
||
imgCount: '{n} image(s)',
|
||
},
|
||
// Round 23: gateway config (admin edits every key of data/gateway.yaml from the UI)
|
||
gc: {
|
||
file: 'Gateway config file',
|
||
fileSub: 'Admin only · applied on save',
|
||
path: 'File',
|
||
restartKeys: 'These need a process restart',
|
||
otherKeys: 'Everything else',
|
||
otherKeysTip: 'Read per request — effective immediately after saving (no restart, no reload wait)',
|
||
saveTip: 'Saving rewrites the whole config file from this page (the old file is backed up as .bak first); secrets are never sent to the browser — only whether they are set.',
|
||
viewYaml: 'View config file',
|
||
save: 'Save & apply',
|
||
saved: 'Saved and applied',
|
||
discard: 'Discard changes',
|
||
editorTitle: 'Config file (gateway.yaml)',
|
||
editorSub: 'Edit the full YAML; click Save to apply',
|
||
exportCfg: 'Export config',
|
||
importCfg: 'Import config',
|
||
importCfgOk: 'Config imported into editor — click Save to apply',
|
||
envTitle: 'API key env vars',
|
||
envSub: 'Stored in data/.env; hidden by default, show / copy / edit',
|
||
envExport: 'Export vars',
|
||
envImport: 'Import vars',
|
||
envImportErr: 'Import vars failed',
|
||
envEmpty: 'No provider uses token_env',
|
||
envSet: 'Set',
|
||
envMissing: 'Missing',
|
||
envShow: 'Show',
|
||
envHide: 'Hide',
|
||
envCopy: 'Copy',
|
||
envCopied: 'Copied',
|
||
envSaved: 'Saved to env & applied',
|
||
saveOk: 'Saved and applied',
|
||
restartPill: 'Restart required',
|
||
restartSaved: 'Changed restart-needed keys: {keys} — take effect after restart',
|
||
backup: 'Backup',
|
||
restore: 'Restore',
|
||
backupOk: 'Backup exported (config + API keys)',
|
||
restoreConfirm: 'This will overwrite the current config and {envs} API-key env vars. Restore?',
|
||
restoreGo: 'Restore',
|
||
cancel: 'Cancel',
|
||
restoreOk: 'Config & API keys restored',
|
||
restoreInvalid: 'Invalid backup file',
|
||
|
||
errTitle: 'Save failed — nothing was changed',
|
||
needRestart: 'restart',
|
||
restartApplied: 'Saved. These need an api-gateway restart to take effect: {keys}',
|
||
savedRestart: 'Saved and applied',
|
||
addItem: 'Add',
|
||
addModel: 'Add model',
|
||
addProvider: 'Add provider',
|
||
addRoute: 'Add route alias',
|
||
addPrice: 'Add pricing',
|
||
delete: 'Delete',
|
||
delProvider: 'Delete provider',
|
||
delRoute: 'Delete route',
|
||
delConfirm: 'Delete "{name}"? It takes effect once you save.',
|
||
needKey: 'Provider key cannot be empty',
|
||
needRoute: 'Route alias cannot be empty',
|
||
dupKey: '"{name}" is duplicated — please rename',
|
||
newProvider: '(new provider)',
|
||
newRoute: '(new alias)',
|
||
unlimited: 'empty = unlimited',
|
||
useServerTimeout: 'empty = server.timeout',
|
||
mediaEmpty: 'empty = unsupported',
|
||
modelId: 'model id',
|
||
modelDisplay: 'display name',
|
||
hdrKey: 'header',
|
||
hdrVal: 'value',
|
||
tokenSet: 'key configured',
|
||
tokenEnvMissing: 'env var not set',
|
||
tokenKeep: 'empty = keep current',
|
||
tokenEmpty: 'empty = none',
|
||
jump: 'Jump to',
|
||
tabServer: 'Server & security',
|
||
tabServerSub: 'Binding, timeout/retry, rate limits, CORS, session TTL and other runtime switches',
|
||
tabProviders: 'Providers & models',
|
||
tabProvidersSub: 'Key source, base URL, image/video endpoints and the model list per provider',
|
||
tabRoutes: 'Routes & circuit',
|
||
tabRoutesSub: 'Route aliases with their fallback chains (order = priority) plus the circuit breaker',
|
||
tabLog: 'Logs & pricing',
|
||
tabLogSub: 'Log level/format/capacity plus model pricing (CNY per million tokens)',
|
||
tabDownload: 'Download proxy',
|
||
tabDownloadSub: 'CDN hosts allowed for the download proxy and the per-file size limit',
|
||
circuit: 'Provider circuit breaker',
|
||
h_circuit: 'A provider that fails to the threshold within the window is skipped for the cooldown; fallback takes over',
|
||
f_c_enabled: 'Enable circuit breaker',
|
||
f_c_failure_threshold: 'Failure threshold',
|
||
f_c_cooldown: 'Cooldown (s)',
|
||
f_c_window: 'Window (s)',
|
||
h_c_enabled: 'Off = never skip a failing provider (fallback still works)',
|
||
h_c_failure_threshold: 'Opens the circuit once failures reach this count in the window',
|
||
h_c_cooldown: 'While open the provider is skipped; it half-opens automatically after the cooldown',
|
||
h_c_window: 'Counts failures inside the window (not necessarily consecutive)',
|
||
f_host: 'Bind address',
|
||
h_host: '127.0.0.1 keeps it local/reverse-proxy only; 0.0.0.0 exposes the port (auth still always on)',
|
||
f_port: 'Port',
|
||
h_port: 'Production uses 8808 and Nginx points at it — change the proxy too',
|
||
f_timeout: 'Upstream timeout (s)',
|
||
h_timeout: 'Per upstream request; a route-level timeout overrides it',
|
||
f_retry: 'Retries for direct model id',
|
||
h_retry: 'Retries (incl. first try) when calling a real model id instead of a route alias',
|
||
f_health_auth: 'Require auth on /health',
|
||
// vue-i18n parses {...} as a placeholder: literal braces must be written {'{'} / {'}'},
|
||
// otherwise the whole message fails to compile (and the UI using it renders nothing).
|
||
// Double quotes: this message needs the {'{'} literal-brace form (braces are vue-i18n placeholders)
|
||
h_health_auth: "Off = /health only returns {'{'}\"status\":\"ok\"{'}'} for probes, no dashboard data",
|
||
f_hot_reload: 'Config hot reload',
|
||
h_hot_reload: 'Reloads hand-edited files by mtime; saving from this page is always immediate',
|
||
f_hot_reload_interval: 'Hot reload interval (s)',
|
||
h_hot_reload_interval: 'Lower = picks up hand edits sooner, higher = less IO',
|
||
f_metrics_enabled: 'Record metrics',
|
||
h_metrics_enabled: 'Off = /metrics and dashboard counters stop updating (calls still work)',
|
||
f_rate_limit_rps: 'Global QPS per account',
|
||
h_rate_limit_rps: 'Empty = unlimited (provider/route level limits are configured separately)',
|
||
f_max_body_size: 'Max request body (bytes)',
|
||
h_max_body_size: '~2MB = 2000000; keep it generous if you send images',
|
||
f_cors_origins: 'CORS allowed origins',
|
||
h_cors_origins: '"*" lets any website drive this gateway from a browser (spending your quota); use trusted domains in production',
|
||
f_graceful_shutdown: 'Graceful shutdown wait (s)',
|
||
h_graceful_shutdown: 'Seconds to wait for in-flight requests after a stop signal',
|
||
f_batch_max_concurrency: '/batch max concurrency',
|
||
h_batch_max_concurrency: 'Larger client values are clamped to this',
|
||
f_batch_max_items: '/batch max items',
|
||
h_batch_max_items: 'Beyond this → 400',
|
||
f_webhook_allow_private: 'Allow private webhook callbacks',
|
||
h_webhook_allow_private: 'SSRF guard, off by default; enables 192.168./10./loopback callback URLs',
|
||
f_docs_enabled: 'Expose /docs',
|
||
h_docs_enabled: 'FastAPI built-in API docs — off by default (it lists your endpoints)',
|
||
f_auth_fail_limit_per_min: 'Auth failures per minute',
|
||
h_auth_fail_limit_per_min: 'Per source IP; beyond this → 429 (brute-force guard)',
|
||
f_session_ttl_minutes: 'Web session TTL (minutes)',
|
||
h_session_ttl_minutes: 'Login session lifetime, default 1440 = 24h; affects new logins only',
|
||
pKey: 'Internal key',
|
||
h_pKey: 'Identifier in config (also the /health provider key); renaming creates a new one',
|
||
pName: 'Display name',
|
||
pBaseUrl: 'Base URL',
|
||
pTokenEnv: 'Key env var',
|
||
h_pTokenEnv: 'The secret lives in .env; put the variable name here (e.g. AGNES_API_KEY) instead of plaintext',
|
||
pToken: 'Plaintext key',
|
||
h_pToken: 'Only if you do not use an env var; after saving it is never echoed back',
|
||
pRateLimit: 'Provider QPS limit',
|
||
h_pRateLimit: 'Empty = unlimited (shared by all models of this provider)',
|
||
pHeaders: 'Extra headers',
|
||
h_pHeaders: 'Some providers need specific headers (auth/version); leave empty if not',
|
||
pMedia: 'Image / video endpoints',
|
||
h_pMedia: 'Only for non-standard endpoints (Agnes uses its own paths); all empty = no image/video',
|
||
pModels: 'Models',
|
||
h_pModels: 'Model ids must match upstream; vision = accepts image input (preferred for image chats)',
|
||
mVision: 'vision',
|
||
routeHint: 'A route alias is a virtual model name (e.g. wjd): models are tried top-down and only a full failure returns 502. Order = priority.',
|
||
rName: 'Alias',
|
||
h_rName: 'Pass this as "model" when calling',
|
||
rTimeout: 'Per-model timeout (s)',
|
||
h_rTimeout: 'How long a single model may take before switching to the next one',
|
||
rRetry: 'Per-model retries',
|
||
h_rRetry: 'Retries before moving on (incl. first try); 1 = switch immediately',
|
||
rRate: 'Route QPS limit',
|
||
h_rRate: 'Empty = unlimited',
|
||
rModels: 'Fallback chain',
|
||
h_rModels: 'Tried top-down; available ids come from the providers above',
|
||
f_o_log_level: 'Log level',
|
||
h_o_log_level: 'DEBUG is noisy; INFO is fine for production',
|
||
f_o_log_json: 'Structured JSON logs',
|
||
h_o_log_json: 'Enable for ELK / CloudWatch; plain text is nicer for humans',
|
||
f_o_access_log_maxlen: 'Access log capacity',
|
||
h_o_access_log_maxlen: 'Upper bound of "loaded N entries" on the logs page (in-memory ring buffer)',
|
||
pricing: 'Model pricing',
|
||
h_pricing: 'CNY per million tokens, used for estimated_cost_cny; unset = omitted (calls unaffected)',
|
||
priceIn: 'Input price',
|
||
priceOut: 'Output price',
|
||
dlHosts: 'Allowed download hosts',
|
||
h_dlHosts: 'Artifact CDN domains (incl. subdomains); empty = download proxy disabled. Add an entry when the CDN changes',
|
||
f_max_bytes: 'Max file size (bytes)',
|
||
h_max_bytes: 'Default 67108864 = 64MB',
|
||
},
|
||
}
|