fimo 2.11.0 → 2.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/skills/fimo-code/references/frameworks/seo-head.md +8 -0
- package/assets/skills/fimo-studio/references/ai-chat/agents.md +7 -1
- package/assets/skills/fimo-studio/references/ai-chat/default-agents.md +3 -3
- package/assets/skills/fimo-studio/references/ai-chat/routines.md +1 -1
- package/assets/skills/fimo-studio/references/knowledge.md +1 -1
- package/assets/skills/fimo-studio/references/seo-settings.md +1 -1
- package/dist/build/vite/plugins/runtime-env.d.ts +0 -19
- package/dist/build/vite/plugins/runtime-env.js +23 -1
- package/dist/cli/bundle.json +2 -2
- package/dist/cli/index.js +12 -10
- package/dist/runtime/seo/resolver.d.ts +9 -1
- package/dist/runtime/seo/resolver.js +16 -2
- package/dist/runtime/seo/schemas.d.ts +1 -1
- package/dist/runtime/seo/schemas.js +6 -4
- package/dist/runtime/seo/server.js +3 -2
- package/package.json +8 -8
- package/templates/astro/package.json +4 -3
- package/templates/nextjs/package.json +4 -4
- package/templates/react-router/.fimo/config.json +0 -3
- package/templates/react-router/package.json +5 -5
- package/templates/react-router/vite.config.ts +1 -1
- package/templates/sveltekit/package.json +3 -3
- package/templates/vite/.fimo/config.json +0 -3
- package/templates/vite/package.json +5 -5
- package/templates/react-router/public/robots.txt +0 -4
|
@@ -45,6 +45,10 @@ and description from the same loaded entry or singleton as the visible page,
|
|
|
45
45
|
including Home/About. Pass that data to resolution or compose its current
|
|
46
46
|
values before conversion. A correct first render does not prove editability.
|
|
47
47
|
|
|
48
|
+
Write a title of about 60 characters or 600 px at most, and a description of
|
|
49
|
+
about 160 characters or 920 px at most: Google cuts the rest, and
|
|
50
|
+
`fimo site check --topic meta-tags` flags it.
|
|
51
|
+
|
|
48
52
|
App values win only where intentionally required. Keep overrides together and
|
|
49
53
|
record their reason in the existing code or handoff, not a new ownership
|
|
50
54
|
registry. Set `image: undefined` to remove a
|
|
@@ -53,6 +57,10 @@ explicit `undefined` in a spread removes a field; use conditional spreads to
|
|
|
53
57
|
retain defaults for missing optional overrides. Resolve once, then compose;
|
|
54
58
|
do not resolve again after applying policy.
|
|
55
59
|
|
|
60
|
+
A resolved `seo.url` is the site's address: the platform's `FIMO_SITE_URL` when
|
|
61
|
+
set, otherwise the value in `.fimo/config.json` for local and self-hosted builds.
|
|
62
|
+
Read it from the resolved SEO, not from the imported config.
|
|
63
|
+
|
|
56
64
|
Pass a final absolute canonical URL from the app's production URL policy.
|
|
57
65
|
`new URL(pathname, seo.url).href` fits a root-hosted starter; preserve existing
|
|
58
66
|
base paths, domains, trailing slashes and query policy in other apps. Never use
|
|
@@ -23,12 +23,18 @@ An agent is a chat with a job: a name, a one-line summary for people, and instru
|
|
|
23
23
|
|
|
24
24
|
Until then, only its creator sees it (**New agent**, **Setting up…**), its routines do not run, and its chat changes nothing on the site: it reads the site, its data and the web, with no CLI, files, work sessions or publish. It goes live only after the person saw its latest draft. When the person names no exact time for a routine, Fimo keeps the hour and picks the minute. Anyone can set up a draft; below Pro, **Create agent** opens the plans.
|
|
25
25
|
|
|
26
|
+
A chat can also create an agent on Pro, live at once, when a person asks for one or says yes to an offer that names a new one.
|
|
27
|
+
|
|
28
|
+
## Read an agent's draft
|
|
29
|
+
|
|
30
|
+
A new page an agent leaves for a person shows as a `drafts` block in the chat: one line per page: its title, with a spinner while it is written, an arrow when it is ready to read, a check once approved, and the title crossed out once discarded. A line opens the page in a tab beside the chat, on the draft's own work: title, the fields that describe it folded under **Details**, then its cover image and text. There a person edits directly, asks for a change from selected words or the sparkle beside a field's name, undoes it with **Undo** or Ctrl+Z, and chooses **Approve** or **Discard**. A change asked for there runs on its own, so the chat stays free, and the chat's agent learns the draft changed on the next message. Without tabs beside a chat, or on a phone, the page opens alone.
|
|
31
|
+
|
|
26
32
|
## Use and change an agent
|
|
27
33
|
|
|
28
34
|
- In an agent, the header shows its name alone and the message box reads **Message <name>**. An empty default agent greets in its own words and offers starter requests; its description stays in its settings. A starter is sent as shown, by anyone who can send messages.
|
|
29
35
|
- Ask the agent to change its instructions; it uses its `agent` tool, and the chat shows **Updated instructions** with **View change** (before and after).
|
|
30
36
|
- The agent's settings have **Summary** and **Instructions** (shared with everyone; empty means none) and an **Instruction history**, where **Restore previous** puts back the text a change replaced.
|
|
31
|
-
- A default agent is Fimo's: its name, summary, instructions and portrait cannot change on any plan.
|
|
37
|
+
- A default agent is Fimo's: its name, summary, instructions and portrait cannot change on any plan. Fimo's routines on it can be switched off and on, or deleted (a deleted one stays deleted), but not changed (`routine_is_default`). On Pro, the team can add routines of its own to a default agent or to an agent of its own (`routine_needs_pro` below Pro); any chat can create one on the agent whose work it is. A routine Fimo retires stops running and leaves the list.
|
|
32
38
|
- In text, an agent links another as `[Name](agent://id)`, shown as a chip that opens it.
|
|
33
39
|
|
|
34
40
|
## Default agents
|
|
@@ -11,11 +11,11 @@ Plans, setup and the rules every default agent follows are in `ai-chat/agents`.
|
|
|
11
11
|
- **Hreflang:** on a site in more than one language, each version lists the others.
|
|
12
12
|
- **Internal linking:** orphan pages, pages more than three clicks deep, and articles with no link to a hub or product page or more than eight links. Runs on changes and every Monday.
|
|
13
13
|
- **Keyword optimization** (every Tuesday, needs Search Console): for pages ranking 8th to 20th it writes a title and headings from the searches that bring visitors, keeps the old words, and checks 8 weeks later whether they helped; on a clear loss it puts the old words back.
|
|
14
|
-
- **Keyword research** (2nd of each month):
|
|
14
|
+
- **Keyword research** (2nd of each month): proposes at most five pages and asks which to write; the Content agent's Writing routine writes the ones picked.
|
|
15
15
|
|
|
16
16
|
The Monday runs of Technical SEO, Meta tags and Internal linking read every page of main's hosted preview, for what no single change shows (pages out of the sitemap, shared titles, title shape, orphan and deep pages). A run that a change started checks only the pages it touches, its first run too.
|
|
17
17
|
|
|
18
|
-
Alone, it points a link at a new address only after it checked that the address shows the same content in the same language, and otherwise removes a dead link and keeps its words; it adds a link on words the text already uses to name another page, keeps the 8 most useful links on a page with too many, shortens a title or description Google cuts from the same words (in a field only search reads, added to the type when needed, when the title is also the page's heading), sets the public address when the canonicals and sitemap agree on it, and adds a 301 from a page's old address once the same page is live at the new one. A title, description, heading or link
|
|
18
|
+
Alone, it points a link at a new address only after it checked that the address shows the same content in the same language, and otherwise removes a dead link and keeps its words; it adds a link on words the text already uses to name another page, keeps the 8 most useful links on a page with too many, shortens a title or description Google cuts from the same words (in a field only search reads, added to the type when needed, when the title is also the page's heading), sets the public address when the canonicals and sitemap agree on it, and adds a 301 from a page's old address once the same page is live at the new one. A title, description, heading or link that any agent or person changed is not changed again for 8 weeks (Google needs 8 to 12 weeks to show the effect), unless it is a fault, and words a person rewrote after an agent changed them stay. Keyword research never changes the site alone.
|
|
19
19
|
|
|
20
20
|
## GEO (4 routines)
|
|
21
21
|
|
|
@@ -32,7 +32,7 @@ Alone, it writes a missing llms.txt and keeps its lines in step with the pages a
|
|
|
32
32
|
- **Content lifecycle** (new content pages, and every three months): thin pages, pages that repeat another, and pages nothing links to that are also thin or out of date.
|
|
33
33
|
- **Translation:** CMS entries missing in a locale, or older than their source. On a one-language site it stops at once.
|
|
34
34
|
- **Editable copy:** off until someone switches it on, or runs once with **Run now**. It moves words typed in the code into labels, and lists into the CMS.
|
|
35
|
-
- **Competitors** (1 January, April, July, October) and **Writing** (
|
|
35
|
+
- **Competitors** (1 January, April, July, October) and **Writing** (when a person picks a page or asks for one: it writes the page in a work session and asks for review; it never publishes).
|
|
36
36
|
|
|
37
37
|
Alone, it translates missing entries only for a type the team already keeps in that locale, and outdated entries, in the site's tone, keeping slugs, dates, numbers, references and media. A new locale or type, a price and a legal page are translated only after a person agreed. It renders a copyright year from the date when the year is typed in the code of one component or layout; a year in a CMS entry or in several places is proposed. Any other sentence a visitor reads is asked, quoting the exact words. Merging, redirecting or retiring a page is only proposed.
|
|
38
38
|
|
|
@@ -4,7 +4,7 @@ A routine is saved instructions that an agent runs in a thread of its own: by ha
|
|
|
4
4
|
|
|
5
5
|
## Create and change
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Any chat, an agent's or a regular one, creates, changes, runs and deletes the project's routines with its `routines` tool. A person asks in any chat ("check the prices every Monday", "run after each publish", "pause the link sweep"), and the routine goes on the agent whose job it is. Studio only shows routines. Routines of your own need Pro; a default routine can only be switched off and on, or deleted.
|
|
8
8
|
|
|
9
9
|
## Triggers
|
|
10
10
|
|
|
@@ -4,6 +4,6 @@ Open **Settings → Knowledge**. This is shared guidance for the whole site: bra
|
|
|
4
4
|
|
|
5
5
|
Managers can write Markdown directly, or click **Draft from website**. The AI action runs in the background and fills the same text field. Read or edit the result, then click **Save knowledge**. Only Save changes the shared setting; Cancel restores the saved text. An empty setting is valid.
|
|
6
6
|
|
|
7
|
-
Viewers and ordinary editors can read knowledge. Managers and explicitly authorized agents can save it. Agent writes require an explicit user request. Each save replaces the current text; there is no knowledge version history or conflict workflow.
|
|
7
|
+
Viewers and ordinary editors can read knowledge. Managers and explicitly authorized agents can save it. Agent writes require an explicit user request, or a routine whose job is to keep a section there, such as Competitors. Each save replaces the current text; there is no knowledge version history or conflict workflow.
|
|
8
8
|
|
|
9
9
|
Agents use saved guidance when proposing, planning, designing, coding, or writing for the site. Changes apply on the next context refresh. Do not ask users to fill an empty setting unless their current task needs missing information.
|
|
@@ -10,7 +10,7 @@ Upload a small square image (32x32 or 64x64 pixels). This is the tiny icon that
|
|
|
10
10
|
|
|
11
11
|
### Website Title
|
|
12
12
|
|
|
13
|
-
This is the name that appears in browser tabs and as the main headline in Google search results. Pick something clear and descriptive.
|
|
13
|
+
This is the name that appears in browser tabs and as the main headline in Google search results. Pick something clear and descriptive, and keep it under 60 characters: Google cuts a longer title.
|
|
14
14
|
|
|
15
15
|
### Website Description
|
|
16
16
|
|
|
@@ -1,22 +1,3 @@
|
|
|
1
1
|
import type { Plugin } from 'vite';
|
|
2
|
-
/**
|
|
3
|
-
* Point the app at the Fimo env of the current git branch.
|
|
4
|
-
*
|
|
5
|
-
* One rule, per variable: anything already set — by the process env (sandbox,
|
|
6
|
-
* shell) or the user's own `.env*` files, read through Vite's `loadEnv` — is
|
|
7
|
-
* left alone; derivation fills only what is missing. A value a user wrote by
|
|
8
|
-
* hand is an override, and this plugin must never win over it. Empty or
|
|
9
|
-
* `undefined` `define` placeholders generated from a missing env are not values.
|
|
10
|
-
*
|
|
11
|
-
* Two injection paths, both needed:
|
|
12
|
-
* - `process.env`, so Vite's own `VITE_*` exposure, `loadEnv`, and server-side
|
|
13
|
-
* code (`getFimoPaths`, SSR) all see the value.
|
|
14
|
-
* - `define` for the public runtime keys, explicit or derived. Fimo's own
|
|
15
|
-
* template `define`s two of them from `loadEnv` at user-config time — before
|
|
16
|
-
* any plugin can run — which yields `undefined` on a bare checkout; a
|
|
17
|
-
* plugin's `define` merges over the user's, so this is what makes the client
|
|
18
|
-
* see the URL. Never over a non-empty user `define`, which stays
|
|
19
|
-
* authoritative.
|
|
20
|
-
*/
|
|
21
2
|
export default function runtimeEnvPlugin(): Plugin;
|
|
22
3
|
//# sourceMappingURL=runtime-env.d.ts.map
|
|
@@ -20,6 +20,25 @@ import { findStaleFimoOverride, resolveLocalRuntimeEnv, staleOverrideMessage, }
|
|
|
20
20
|
* see the URL. Never over a non-empty user `define`, which stays
|
|
21
21
|
* authoritative.
|
|
22
22
|
*/
|
|
23
|
+
// A dev restart after a `.env` change reruns the plugin in the same process, where
|
|
24
|
+
// `process.env` still holds the old value, and `loadEnv` lets `process.env` win.
|
|
25
|
+
let siteUrlFromDotenv;
|
|
26
|
+
function forgetSiteUrlFromDotenv() {
|
|
27
|
+
if (siteUrlFromDotenv !== undefined && process.env.FIMO_SITE_URL === siteUrlFromDotenv) {
|
|
28
|
+
delete process.env.FIMO_SITE_URL;
|
|
29
|
+
}
|
|
30
|
+
siteUrlFromDotenv = undefined;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Server code reads `FIMO_SITE_URL` from `process.env`, which Vite does not fill
|
|
34
|
+
* from `.env`, the only place a dev server or hosted preview gets a public variable.
|
|
35
|
+
*/
|
|
36
|
+
function fillSiteUrlFromDotenv(dotenv) {
|
|
37
|
+
if (!process.env.FIMO_SITE_URL && dotenv.FIMO_SITE_URL) {
|
|
38
|
+
siteUrlFromDotenv = dotenv.FIMO_SITE_URL;
|
|
39
|
+
process.env.FIMO_SITE_URL = siteUrlFromDotenv;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
23
42
|
export default function runtimeEnvPlugin() {
|
|
24
43
|
// External SSR dependencies bypass Vite's define replacements.
|
|
25
44
|
const ssr = { noExternal: ['fimo', 'fimo-react', 'fimo-sveltekit'] };
|
|
@@ -44,7 +63,10 @@ export default function runtimeEnvPlugin() {
|
|
|
44
63
|
// plugin, but `import('fimo/vite/runtime-env')` is also a valid package
|
|
45
64
|
// boundary probe for projects that only install the core runtime.
|
|
46
65
|
const { loadEnv } = await import('vite');
|
|
47
|
-
|
|
66
|
+
forgetSiteUrlFromDotenv();
|
|
67
|
+
const dotenv = loadEnv(mode, config.envDir ?? cwd, '');
|
|
68
|
+
fillSiteUrlFromDotenv(dotenv);
|
|
69
|
+
const explicit = { ...dotenv, ...process.env };
|
|
48
70
|
const define = {
|
|
49
71
|
'process.env.FIMO_EDITING_METADATA': JSON.stringify(String(resolveFimoEditingMetadata(command === 'serve' && mode !== 'production' && explicit.NODE_ENV !== 'production'
|
|
50
72
|
? 'development'
|
package/dist/cli/bundle.json
CHANGED