diff --git a/components/Layout.tsx b/components/Layout.tsx index a67815a..c3a9ffa 100644 --- a/components/Layout.tsx +++ b/components/Layout.tsx @@ -6,9 +6,8 @@ import { ReactNode } from 'react'; const LINKS = [ { href: '/', label: 'Overview' }, { href: '/papers', label: 'Papers' }, - { href: '/work-types', label: 'Types of work' }, - { href: '/benchmarks', label: 'Benchmarks' }, - { href: '/taxonomy', label: 'Taxonomy' }, + { href: '/landscape', label: 'Landscape' }, + { href: '/contents', label: 'Contents' }, ]; export default function Layout({ title, children }: { title?: string; children: ReactNode }) { diff --git a/components/LegacyTypeView.tsx b/components/LegacyTypeView.tsx index 6e01d8d..4492ff7 100644 --- a/components/LegacyTypeView.tsx +++ b/components/LegacyTypeView.tsx @@ -14,7 +14,7 @@ export default function LegacyTypeView({ data, page, llm, slug }: { data: Data; const withScores = results.length > 0; return ( -

← All types of work

+

← All types of work

{role.label}

in {area.label} · {type.n_papers.toLocaleString()} papers ({type.n_llm_labeled} labelled in detail)

diff --git a/lib/content.ts b/lib/content.ts new file mode 100644 index 0000000..95133a4 --- /dev/null +++ b/lib/content.ts @@ -0,0 +1,72 @@ +import { one, query } from './db'; +import { listReviews } from './reviews'; +import { Area, Role } from './worktypes'; + +/** Your tree of content. Add nodes here; each node pulls its numbers from the areas / taxonomy nodes it lists. */ +export interface ContentNode { + id: string; + title: string; + blurb: string; + areas: string[]; // work-type areas (areas.id) + taxonomy: string[]; // taxonomy node ids + children: ContentNode[]; +} + +export const CONTENT_TREE: ContentNode = { + id: 'root', + title: 'Contents', + blurb: 'The structure of the survey write-up.', + areas: [], + taxonomy: [], + children: [ + { + id: 'tools-of-agents', + title: 'Tools of agents', + blurb: 'How agents call tools: function calling, MCP, API use and tool-integrated reasoning.', + areas: ['tool-use'], + taxonomy: ['agents/tools'], + children: [], + }, + ], +}; + +export function findNode(id: string, n: ContentNode = CONTENT_TREE): ContentNode | null { + if (n.id === id) return n; + for (const c of n.children) { const f = findNode(id, c); if (f) return f; } + return null; +} + +export async function getContent(node: ContentNode) { + const areas = await query('SELECT a.*, 0 AS n FROM areas a WHERE a.id = ANY(?) ORDER BY sort', [node.areas]); + const [roles, byRole, benchmarks, taxonomy, papers, total, reviews] = await Promise.all([ + query('SELECT r.*, 0 AS n FROM roles r ORDER BY sort'), + query<{ type_id: string; n: number; n_llm: number }>( + `SELECT type_id, COUNT(*) AS n, SUM((source='llm')::int) AS n_llm FROM paper_work_types WHERE split_part(type_id,'|',1) = ANY(?) GROUP BY type_id`, [node.areas]), + query<{ id: number; name: string; n: number; n_new: number }>( + `SELECT b.id, b.name, COUNT(DISTINCT pb.paper_id) AS n, SUM(pb.is_new) AS n_new + FROM paper_benchmarks pb JOIN benchmarks b ON b.id = pb.bench_id JOIN paper_work_types w ON w.paper_id = pb.paper_id + WHERE split_part(w.type_id,'|',1) = ANY(?) GROUP BY b.id ORDER BY n DESC, b.id LIMIT 12`, [node.areas]), + query<{ id: string; label: string; n: number }>( + `SELECT pt.node_id AS id, t.label, COUNT(DISTINCT pt.paper_id) AS n FROM paper_taxonomy pt JOIN taxonomy t ON t.id = pt.node_id + WHERE pt.node_id = ANY(?) GROUP BY pt.node_id, t.label`, [node.taxonomy]), + query<{ id: number; title: string; conf_short: string; date: string; summary: string | null }>( + `SELECT p.id, p.title, c.short AS conf_short, COALESCE(c.start_date,'2026-06-01') AS date, pm.summary + FROM papers p JOIN conferences c ON c.slug = p.conf LEFT JOIN paper_meta pm ON pm.paper_id = p.id + WHERE p.id IN (SELECT paper_id FROM paper_work_types WHERE split_part(type_id,'|',1) = ANY(?) AND source = 'llm') + ORDER BY date DESC, p.id LIMIT 20`, [node.areas]), + one<{ n: number }>(`SELECT COUNT(DISTINCT paper_id) AS n FROM paper_work_types WHERE split_part(type_id,'|',1) = ANY(?)`, [node.areas]), + listReviews(), + ]); + const cells = new Map(byRole.map((r) => [r.type_id, r])); + return { + areas, + total: total?.n ?? 0, + roles: roles + .map((r) => ({ ...r, cells: node.areas.map((a) => ({ id: `${a}|${r.id}`, ...(cells.get(`${a}|${r.id}`) ?? { n: 0, n_llm: 0 }) })) })) + .filter((r) => r.cells.some((c) => c.n > 0)), + benchmarks, + taxonomy, + papers, + reviews: reviews.filter((r) => node.areas.includes(r.area)), + }; +} diff --git a/next.config.js b/next.config.js index 3dd7ef1..bae6663 100644 --- a/next.config.js +++ b/next.config.js @@ -1,4 +1,12 @@ /** @type {import('next').NextConfig} */ module.exports = { reactStrictMode: true, + // the three list pages were merged into /landscape (query strings are carried over) + async redirects() { + return [ + { source: '/work-types', destination: '/landscape#types', permanent: false }, + { source: '/benchmarks', destination: '/landscape#benchmarks', permanent: false }, + { source: '/taxonomy', destination: '/landscape#taxonomy', permanent: false }, + ]; + }, }; diff --git a/pages/benchmarks/[id].tsx b/pages/benchmarks/[id].tsx index dcede2b..c8d858e 100644 --- a/pages/benchmarks/[id].tsx +++ b/pages/benchmarks/[id].tsx @@ -15,7 +15,7 @@ export default function BenchmarkPage({ data }: { data: Data }) { const { bench, papers, byType, results } = data; return ( -

← All benchmarks

+

← All benchmarks

{bench.name}

{bench.n_papers} papers · introduced in {bench.n_new} of them

diff --git a/pages/benchmarks/index.tsx b/pages/benchmarks/index.tsx deleted file mode 100644 index 8173628..0000000 --- a/pages/benchmarks/index.tsx +++ /dev/null @@ -1,24 +0,0 @@ -import type { GetServerSideProps } from 'next'; -import Link from 'next/link'; -import Layout from '../../components/Layout'; -import { getBenchmarks } from '../../lib/worktypes'; - -interface Props { rows: Awaited> } -export const getServerSideProps: GetServerSideProps = async () => ({ props: { rows: await getBenchmarks(2) } }); - -export default function Benchmarks({ rows }: Props) { - return ( - -

Benchmarks

-

Benchmarks named in at least two papers’ abstracts. Extracted from the detailed agent-paper labels and matched by name in the remaining papers.

- - - - {rows.map((b) => ( - - ))} - -
BenchmarkPapersIntroduced in 2026Scores recorded
{b.name}{b.n_papers}{b.n_new || ''}{b.n_results || ''}
-
- ); -} diff --git a/pages/conferences/[slug].tsx b/pages/conferences/[slug].tsx index a2163d6..0d289c8 100644 --- a/pages/conferences/[slug].tsx +++ b/pages/conferences/[slug].tsx @@ -34,7 +34,7 @@ export default function ConferencePage({ conf, tops, tracks }: Props) { {t.label} {t.n.toLocaleString()}

))} - See the full tree with all venues → + See the full tree with all venues →
); diff --git a/pages/contents.tsx b/pages/contents.tsx new file mode 100644 index 0000000..ce3ef39 --- /dev/null +++ b/pages/contents.tsx @@ -0,0 +1,109 @@ +import type { GetServerSideProps } from 'next'; +import Link from 'next/link'; +import Layout from '../components/Layout'; +import { CONTENT_TREE, ContentNode, findNode, getContent } from '../lib/content'; +import { typeSlug } from '../lib/slug'; + +type Content = Awaited>; +interface Props { node: { id: string; title: string; blurb: string; areas: string[]; taxonomy: string[] }; content: Content } + +export const getServerSideProps: GetServerSideProps = async ({ query }) => { + const want = String(query.node ?? CONTENT_TREE.children[0].id); + const node = findNode(want); + if (!node || node.id === 'root') return { notFound: true }; + const { children: _c, ...plain } = node; + return { props: { node: plain, content: await getContent(node) } }; +}; + +function Tree({ node, selected }: { node: ContentNode; selected: string }) { + return ( +
    + {node.children.map((c) => ( +
  • + {c.title} + {c.children.length > 0 && } +
  • + ))} +
+ ); +} + +export default function Contents({ node, content }: Props) { + const area = content.areas[0]; + return ( + +

Contents

+

The tree of content for the write-up. Each entry draws its numbers from the survey data.

+
+ +
+

{node.title}

+

{node.blurb}

+
+
{content.total.toLocaleString()}
papers in this area{area ? ` (${area.label.split(',')[0]})` : ''}
+ {content.taxonomy.map((t) => ( + +
{t.n.toLocaleString()}
in taxonomy: {t.label} + + ))} +
{content.benchmarks.length}
benchmarks most used here
+
+ + {content.reviews.length > 0 && ( + <> +

Reviews

+
+ {content.reviews.map((r) => ( + + {r.title} +
{r.n} papers
+ + ))} +
+ + )} + +

By kind of contribution

+ + + + {content.roles.map((r) => ( + + + + + + + ))} + +
RoleWhat it fixes → variesPapersRead in detail
{r.label}{r.fixes || '—'} → {r.varies || '—'}{r.cells.reduce((s, c) => s + c.n, 0)}{r.cells.filter((c) => c.n > 0).map((c) => {c.n_llm > 0 ? `${c.n_llm} labelled` : 'rule-labelled'})}
+ +

Benchmarks used

+ + + + {content.benchmarks.map((b) => ( + + ))} + +
BenchmarkPapersIntroduced in 2026
{b.name}{b.n}{b.n_new || ''}
+ +

Recent papers (read in detail)

+ {content.papers.map((p) => ( +
+

{p.title}

+
{p.conf_short} · {p.date}
+ {p.summary &&

{p.summary}

} +
+ ))} + {content.taxonomy[0] &&

All papers in “{content.taxonomy[0].label}” →

} +
+
+
+ ); +} diff --git a/pages/index.tsx b/pages/index.tsx index 23bc05b..69f0c2d 100644 --- a/pages/index.tsx +++ b/pages/index.tsx @@ -72,7 +72,7 @@ export default function Home({ conferences, stats, topics, today }: Props) {
))} - Explore the full taxonomy tree → + Explore the full taxonomy tree →
); diff --git a/pages/landscape.tsx b/pages/landscape.tsx new file mode 100644 index 0000000..497b93b --- /dev/null +++ b/pages/landscape.tsx @@ -0,0 +1,159 @@ +import type { GetServerSideProps } from 'next'; +import Link from 'next/link'; +import Layout from '../components/Layout'; +import TaxonomyTree from '../components/TaxonomyTree'; +import { getConferences, getNodeConfBreakdown, getTaxonomyTree } from '../lib/queries'; +import { getBenchmarks, getMatrix } from '../lib/worktypes'; +import { listReviews } from '../lib/reviews'; +import { typeSlug } from '../lib/slug'; +import { TaxNode } from '../lib/types'; + +type Matrix = Awaited>; +interface Props { + matrix: Matrix; + reviews: Awaited>; + benchmarks: Awaited>; + tree: TaxNode[]; + breakdown: Record>; + confLabel: Record; + src: 'llm' | 'all'; + llm: boolean; +} + +export const getServerSideProps: GetServerSideProps = async ({ query }) => { + const src = query.src === 'llm' ? 'llm' : 'all'; + const llm = query.llm === '1'; + const [matrix, reviews, benchmarks, tree, breakdown, confs] = await Promise.all([ + getMatrix({ src }), listReviews(), getBenchmarks(2), getTaxonomyTree({ llm }), getNodeConfBreakdown({ llm }), getConferences(), + ]); + return { props: { matrix, reviews, benchmarks, tree, breakdown, confLabel: Object.fromEntries(confs.map((c) => [c.slug, c.short])), src, llm } }; +}; + +const SECTIONS = [ + { id: 'types', label: 'Types of work' }, + { id: 'benchmarks', label: 'Benchmarks' }, + { id: 'taxonomy', label: 'Taxonomy' }, +]; + +export default function Landscape({ matrix, reviews, benchmarks, tree, breakdown, confLabel, src, llm }: Props) { + const { roles, areas, cells } = matrix; + const max = Math.max(1, ...Object.values(cells)); + const groups: ('agent' | 'general')[] = ['agent', 'general']; + /** link back to this page with one filter changed, keeping the other */ + const here = (patch: { src?: 'llm' | 'all'; llm?: boolean }, hash: string) => { + const s = patch.src ?? src; const l = patch.llm ?? llm; + const sp = new URLSearchParams(); + if (s === 'llm') sp.set('src', 'llm'); + if (l) sp.set('llm', '1'); + const q = sp.toString(); + return `/landscape${q ? '?' + q : ''}#${hash}`; + }; + const q = llm ? '&llm=1' : ''; + return ( + +

Research landscape

+

The three views of the corpus on one page: what kind of work papers do, which benchmarks they use, and where they sit in the topic tree.

+
+ {SECTIONS.map((s) => {s.label})} +
+ +
+

Types of work

+

+ A type of work = research area × role. The role says what a paper contributes and what it holds fixed versus varies, so two papers on the same benchmark land in different types when one + fixes the agent and changes the environment while the other does the opposite. A paper can belong to several types. +

+ {reviews.length > 0 && ( + <> +

Reviews ({reviews.length})

+
+ {reviews.map((r) => ( + +
{areas.find((a) => a.id === r.area)?.label ?? r.area} · {roles.find((x) => x.id === r.role)?.label ?? r.role}
+ {r.title} +
{r.n} papers · {(r.abstract ?? '').slice(0, 160)}…
+ + ))} +
+ + )} +
+ All papers (LLM labels + rules) + Detailed labels only (agent-related, read by LLM) +
+

Roles

+ + + + {roles.map((r) => ( + + ))} + +
RoleFixesVariesWhat it meansPapers
{r.label}{r.fixes || '—'}{r.varies || '—'}{r.descr}{r.n.toLocaleString()}
+ {groups.map((g) => ( +
+

{g === 'agent' ? 'Agent research areas' : 'Other LLM research areas'}

+
+ + + {roles.map((r) => )} + + + {areas.filter((a) => a.kind === g).map((a) => ( + + + {roles.map((r) => { + const id = `${a.id}|${r.id}`; const n = cells[id] ?? 0; + return ( + + ); + })} + + + ))} + +
Area{r.id}Σ
{a.label.length > 52 ? a.label.slice(0, 50) + '…' : a.label} + {n ? {n} : ''} + {a.n.toLocaleString()}
+
+
+ ))} +
+ +
+

Benchmarks

+

Benchmarks named in at least two papers’ abstracts ({benchmarks.length}). Extracted from the detailed agent-paper labels and matched by name in the remaining papers.

+
+ + + + {benchmarks.map((b) => ( + + ))} + +
BenchmarkPapersIntroduced in 2026Scores recorded
{b.name}{b.n_papers}{b.n_new || ''}{b.n_results || ''}
+
+
+ +
+

Taxonomy

+

+ One topic tree across all conferences. Each paper keeps its conference as a tag: the chips next to a topic show how many of its papers come from each venue, and clicking one lists them. +

+
+ {llm ? 'Include non-LLM papers' : 'LLM-related only'} +
+
+ `/papers?node=${id}${q}`} + chipHref={(id, conf) => `/papers?node=${id}&conf=${conf}${q}`} + /> +
+
+
+ ); +} diff --git a/pages/taxonomy.tsx b/pages/taxonomy.tsx deleted file mode 100644 index cf9ac9b..0000000 --- a/pages/taxonomy.tsx +++ /dev/null @@ -1,51 +0,0 @@ -import type { GetServerSideProps } from 'next'; -import Link from 'next/link'; -import Layout from '../components/Layout'; -import TaxonomyTree from '../components/TaxonomyTree'; -import { getConferences, getNodeConfBreakdown, getTaxonomyTree } from '../lib/queries'; -import { TaxNode } from '../lib/types'; - -interface Props { - tree: TaxNode[]; - llm: boolean; - breakdown: Record>; - confLabel: Record; -} - -export const getServerSideProps: GetServerSideProps = async ({ query }) => { - const llm = query.llm === '1'; - const [tree, breakdown, confs] = await Promise.all([getTaxonomyTree({ llm }), getNodeConfBreakdown({ llm }), getConferences()]); - return { - props: { - tree, - llm, - breakdown, - confLabel: Object.fromEntries(confs.map((c) => [c.slug, c.short])), - }, - }; -}; - -export default function Taxonomy({ tree, llm, breakdown, confLabel }: Props) { - const q = llm ? '&llm=1' : ''; - return ( - -

Taxonomy tree

-

- One topic tree across all conferences. Each paper keeps its conference as a tag: the chips next to a topic show how many of its papers come from each venue, and clicking one lists them. -

-
- {llm ? 'Include non-LLM papers' : 'LLM-related only'} -
-
- `/papers?node=${id}${q}`} - chipHref={(id, conf) => `/papers?node=${id}&conf=${conf}${q}`} - /> -
-
- ); -} diff --git a/pages/work-types/[slug].tsx b/pages/work-types/[slug].tsx index e270b29..cf58c0f 100644 --- a/pages/work-types/[slug].tsx +++ b/pages/work-types/[slug].tsx @@ -43,7 +43,7 @@ export default function WorkTypePage(props: Props) { const wf = data.note?.workflow ?? []; return ( -

← All types of work · data view

+

← All types of work · data view

diff --git a/pages/work-types/index.tsx b/pages/work-types/index.tsx deleted file mode 100644 index fa2db29..0000000 --- a/pages/work-types/index.tsx +++ /dev/null @@ -1,85 +0,0 @@ -import type { GetServerSideProps } from 'next'; -import Link from 'next/link'; -import Layout from '../../components/Layout'; -import { Area, Role, getMatrix } from '../../lib/worktypes'; -import { typeSlug } from '../../lib/slug'; -import { listReviews } from '../../lib/reviews'; - -interface Props { roles: Role[]; areas: Area[]; cells: Record; src: 'llm' | 'all'; reviews: Awaited> } - -export const getServerSideProps: GetServerSideProps = async ({ query }) => { - const src = query.src === 'llm' ? 'llm' : 'all'; - return { props: { ...(await getMatrix({ src })), src, reviews: await listReviews() } }; -}; - -export default function WorkTypes({ roles, areas, cells, src, reviews }: Props) { - const max = Math.max(1, ...Object.values(cells)); - const groups: ('agent' | 'general')[] = ['agent', 'general']; - return ( - -

Types of work

-

- A type of work = research area × role. The role says what a paper contributes and what it holds fixed versus varies, so two papers on the same benchmark land in different types when one - fixes the agent and changes the environment while the other does the opposite. A paper can belong to several types. -

- {reviews.length > 0 && ( - <> -

Reviews ({reviews.length})

-
- {reviews.map((r) => ( - -
{areas.find((a) => a.id === r.area)?.label ?? r.area} · {roles.find((x) => x.id === r.role)?.label ?? r.role}
- {r.title} -
{r.n} papers · {(r.abstract ?? '').slice(0, 160)}…
- - ))} -
-

All types (area × role)

- - )} -
- All papers (LLM labels + rules) - Detailed labels only (agent-related, read by LLM) -
- -

Roles

- - - - {roles.map((r) => ( - - ))} - -
RoleFixesVariesWhat it meansPapers
{r.label}{r.fixes || '—'}{r.varies || '—'}{r.descr}{r.n.toLocaleString()}
- - {groups.map((g) => ( -
-

{g === 'agent' ? 'Agent research areas' : 'Other LLM research areas'}

-
- - - {roles.map((r) => )} - - - {areas.filter((a) => a.kind === g).map((a) => ( - - - {roles.map((r) => { - const id = `${a.id}|${r.id}`; const n = cells[id] ?? 0; - return ( - - ); - })} - - - ))} - -
Area{r.id}Σ
{a.label.length > 52 ? a.label.slice(0, 50) + '…' : a.label} - {n ? {n} : ''} - {a.n.toLocaleString()}
-
-
- ))} -
- ); -} diff --git a/styles/globals.css b/styles/globals.css index 5b0edf3..176e092 100644 --- a/styles/globals.css +++ b/styles/globals.css @@ -64,3 +64,10 @@ sup.cite{font-size:11px;margin-left:1px}sup.cite a{text-decoration:none} .refs{font-size:13.5px;padding-left:28px}.refs li{margin:4px 0}.refs li:target{background:var(--accent-bg)} .qa-ok{color:#1b9e77;font-weight:600}.qa-fixed{color:#e0702b;font-weight:600} details.extract summary{cursor:pointer;font-weight:600;margin:8px 0} + +/* landscape: in-page section tabs */ +.tabs{display:flex;gap:6px;position:sticky;top:49px;z-index:4;background:var(--bg);padding:8px 0;margin-bottom:4px;border-bottom:1px solid var(--line)} +.tabs a{padding:5px 14px;border:1px solid var(--line);border-radius:99px;background:var(--card);color:var(--fg)} +.tabs a:hover{border-color:var(--accent);text-decoration:none} +section[id]{scroll-margin-top:100px} +h3{font-size:16px;margin:18px 0 8px}