AgentSkillsCN

data-analysis

基于人工智能的数据分析功能,助力“共情分类账”——主题提炼、金句摘录、故事创意推荐、文本转录分析。

SKILL.md
--- frontmatter
name: data-analysis
description: AI-powered data analysis for Empathy Ledger - themes, quotes, story suggestions, transcript analysis.

Data Analysis

Patterns for AI-powered analysis: themes, quotes, summaries, and story suggestions.

When to Use

  • Adding quotes to story cards
  • Implementing story suggestions/related content
  • Building theme-based filtering or search
  • Creating analytics dashboards
  • Integrating AI analysis results

Quick Reference

Analysis Pipeline

code
Transcript → AI Analysis → themes[], key_quotes[], ai_summary
Story → Connections → Related Stories, Suggested Content

Key Tables

TableAnalysis Fields
transcriptsthemes, key_quotes, ai_summary, ai_processing_status
storiesthemes, cultural_tags, featured_quote
storytellersexpertise_themes, connection_strength

Theme Categories

  • cultural: identity, heritage, tradition, language, ceremony
  • family: kinship, elders, children, ancestors, community
  • land: country, connection, seasons, wildlife, sacred-sites
  • resilience: survival, adaptation, strength, healing, hope
  • knowledge: wisdom, teaching, learning, stories, dreams

Common Queries

sql
-- Stories with matching theme
SELECT * FROM stories WHERE themes && ARRAY['identity', 'heritage'];

-- Theme frequency
SELECT unnest(themes) as theme, count(*) FROM stories GROUP BY theme ORDER BY count DESC;

API Endpoints

EndpointPurpose
POST /api/transcripts/{id}/analyzeTrigger AI analysis
GET /api/stories/{id}/suggestionsGet related stories
GET /api/themesList themes with counts

Reference Files

TopicFile
Code patternsrefs/analysis-patterns.md
SQL queriesrefs/supabase-queries.md
Theme hierarchyrefs/theme-taxonomy.md
Sync statusrefs/sync-status.md

Related Skills

  • database-navigator - Database exploration
  • supabase-connection - Database clients
  • design-component - UI patterns for analysis display