ai-context-engineering/index.sql
SELECT 'dynamic' AS component, sqlpage.run_sql('shell/shell.sql') AS properties;
SELECT 'breadcrumb' as component;
WITH RECURSIVE breadcrumbs AS (
SELECT
COALESCE(abbreviated_caption, caption) AS title,
COALESCE(url, path) AS link,
parent_path, 0 AS level,
namespace
FROM sqlpage_aide_navigation
WHERE namespace = 'prime' AND path='ai-context-engineering/index.sql'
UNION ALL
SELECT
COALESCE(nav.abbreviated_caption, nav.caption) AS title,
COALESCE(nav.url, nav.path) AS link,
nav.parent_path, b.level + 1, nav.namespace
FROM sqlpage_aide_navigation nav
INNER JOIN breadcrumbs b ON nav.namespace = b.namespace AND nav.path = b.parent_path
)
SELECT title ,
sqlpage.environment_variable('SQLPAGE_SITE_PREFIX') || '/'||link as link
FROM breadcrumbs ORDER BY level DESC;
-- not including page title from sqlpage_aide_navigation
select
'card' as component,
4 as columns;
select
'## Total Counts of Prompt Module' as description_md,
'white' as background_color,
'## ' || count(DISTINCT uri) as description_md,
'12' as width,
'pink' as color,
'timeline-event' as icon,
'background-color: #FFFFFF' as style,
sqlpage.environment_variable('SQLPAGE_SITE_PREFIX') || '/ai-context-engineering/prompts.sql' as link
FROM ai_ctxe_uniform_resource_prompts;
select
'## Total counts of Merge Group' as description_md,
'white' as background_color,
'## ' || count(DISTINCT merge_group) as description_md,
'12' as width,
'pink' as color,
'timeline-event' as icon,
'background-color: #FFFFFF' as style,
sqlpage.environment_variable('SQLPAGE_SITE_PREFIX') || '/ai-context-engineering/merge-group.sql' as link
FROM ai_ctxe_uniform_resource_prompts;
select
'## Ingest Health' as description_md,
'white' as background_color,
'12' as width,
'green' as color,
'file-plus' as icon,
'background-color: #FFFFFF' as style,
sqlpage.environment_variable('SQLPAGE_SITE_PREFIX') || '/ai-context-engineering/ingest-health.sql' as link;
select
'## Risk/QA Panel' as description_md,
'white' as background_color,
'12' as width,
'red' as color,
'alert-circle' as icon,
'background-color: #FFFFFF' as style,
sqlpage.environment_variable('SQLPAGE_SITE_PREFIX') || '/ai-context-engineering/risk.sql' as link;
select
'card' as component,
4 as columns;
select
'## Total Count of Prompts fed into AnythingLLM' as description_md,
'white' as background_color,
'## ' || count(DISTINCT uri) as description_md,
'12' as width,
'pink' as color,
'timeline-event' as icon,
'background-color: #FFFFFF' as style,
sqlpage.environment_variable('SQLPAGE_SITE_PREFIX') || '/ai-context-engineering/prompts-anythingllm.sql' as link
FROM uniform_resource_build_anythingllm;