[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6WM6TBJ2XJJN0FS3XRF3CCP":3,"skill-same:01M6WM6TBJ2XJJN0FS3XRF3CCP":57},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":31,"linkOnly":32,"markdownContent":33,"markdownBody":34,"frontMatter":35,"refName":36,"commitSha":37,"skillDirectory":38,"forksCount":39,"repositoryHtmlUrl":40,"repositoryHomepageUrl":6,"ownerHtmlUrl":41,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":42,"install":43,"resources":56},"01M6WM6TBJ2XJJN0FS3XRF3CCP","firebase-prod-campaigns",null,"Query and reason about production Firestore campaign and user data for WorldArchitect.AI.","jleechanorg\u002Fjleechan-skills","jleechanorg","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F221404966?v=4","01M6C1VJ99XG950X1DWPEBCBGX","01M6C1VJDK5YVDNT3362RT5WSB",6,"MIT","https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fworldarchitect\u002Fskills\u002Ffirebase-prod-campaigns\u002FSKILL.md",[],[18,19,20,21,22,23,24,25,26,27,28,29,30],"firebase","firebase prod campaigns","campaigns","data","Production","user","campaign","worldarchitect","firestore","query","about","for","reason","2026-11-10 10:12:30",false,"---\nname: firebase-prod-campaigns\ndescription: Query and reason about production Firestore campaign and user data for WorldArchitect.AI.\n---\n\n# Firebase Production Campaign Database Access\n\n## Overview\nThis skill documents how to query the **production Firestore database** for Your Project campaigns and user data.\n\n## CRITICAL: Campaign Lookup\n\n**Campaigns are NESTED under users, NOT at root level!**\n\n```python\n# WRONG - This queries the wrong collection (test data only):\ndb.collection('campaigns').document('CAMPAIGN_ID')\n\n# CORRECT - Campaigns are nested under user UID:\ndb.collection('users').document(uid).collection('campaigns').document('CAMPAIGN_ID')\n```\n\n### Quick Lookup for Known Campaign ID\n```python\n# 1. Get user UID from the supplied email\nuser_record = auth.get_user_by_email('user@example.invalid')\nuid = user_record.uid\n\n# 2. Query nested path\ndoc = db.collection('users').document(uid).collection('campaigns').document('CAMPAIGN_ID').get()\n```\n\n## Database Structure\n\n```\nFirestore Database: $FIREBASE_PROJECT_ID\n├── campaigns\u002F                    # ← WRONG: Only test data here (5 campaigns)\n│   └── {test_campaign_id}\u002F\n│\n└── users\u002F                        # ← CORRECT: Real user data here (146+ campaigns)\n    └── {Firebase_Auth_UID}\u002F      # e.g., \u003Cfirebase-auth-uid>\n        └── campaigns\u002F\n            └── {campaign_id}\u002F    # e.g., \u003Ccampaign-id>\n                ├── title         # \"Example campaign\"\n                ├── created_at\n                ├── last_played\n                ├── world_name\n                ├── game_states\u002F              # ← SUBCOLLECTION for game state\n                │   └── current_state\u002F        # Main game state document\n                │       ├── player_character_data\n                │       ├── combat_state\n                │       ├── npc_data\n                │       └── custom_campaign_state\u002F\n                │           └── god_mode_directives[]  # ← Persisted rules\n                └── story\u002F\n                    └── {entry_id}\u002F\n                        ├── actor (user\u002Fgemini)\n                        ├── text\n                        └── timestamp\n```\n\n## IMPORTANT: Game State Location\n\n**Game state is in a SUBCOLLECTION, not a field!**\n\n```python\n# WRONG - game_state is NOT a field on the campaign document:\ncampaign = db.collection('users').document(uid).collection('campaigns').document(campaign_id).get()\ngame_state = campaign.to_dict().get('game_state')  # Returns empty!\n\n# CORRECT - game_state is in a subcollection called 'game_states':\ngame_state_ref = db.collection('users').document(uid).collection('campaigns').document(campaign_id).collection('game_states').document('current_state')\ngame_state = game_state_ref.get().to_dict()\n```\n\n### Querying God Mode Directives\n\n```python\n# Get god mode directives for a campaign\ngame_state_ref = campaign_ref.collection('game_states').document('current_state')\ngame_state = game_state_ref.get().to_dict()\n\ncustom_campaign_state = game_state.get('custom_campaign_state', {})\ngod_mode_directives = custom_campaign_state.get('god_mode_directives', [])\n\nfor directive in god_mode_directives:\n    if isinstance(directive, dict):\n        print(f\"Rule: {directive.get('rule')}\")\n        print(f\"Added: {directive.get('added')}\")\n```\n\n### Using the Directive Query Script\n\n```bash\n# List all directives for a campaign\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fquery_directives.py CAMPAIGN_ID\n\n# Debug why a directive wasn't saved\npython scripts\u002Fquery_directives.py CAMPAIGN_ID --debug-missing \"power scaling\"\n\n# Manually add a missing directive\npython scripts\u002Fquery_directives.py CAMPAIGN_ID --email \"user@example.com\" --add \"Level 9 is extremely powerful - never use 'mere' or 'modest'\"\n```\n\n## Debugging Missing God Mode Directives\n\nWhen a user's god mode request doesn't result in a saved directive, follow this process:\n\n### 1. How Directives Are Saved\n\nThe LLM must return a `directives` field in its structured JSON response:\n\n```json\n{\n    \"god_mode_response\": \"Acknowledged...\",\n    \"directives\": {\n        \"add\": [\"Rule to remember going forward\"],\n        \"drop\": [\"Rule to stop following\"]\n    }\n}\n```\n\n**Processing code:** `$PROJECT_ROOT\u002Fworld_logic.py:1585-1667`\n**Prompt instructions:** `$PROJECT_ROOT\u002Fprompts\u002Fgod_mode_instruction.md:72-96`\n\n### 2. Common Failure Modes\n\n| Symptom | Cause | Solution |\n|---------|-------|----------|\n| Directive acknowledged but not saved | LLM returned `god_mode_response` but no `directives.add` | Check raw LLM response |\n| Directive in `dm_notes` only | LLM put rule in `state_updates.debug_info.dm_notes` | `dm_notes` are now injected into future prompts as part of the system prompt |\n| Empty `god_mode_directives` list | No directives ever saved | Check story entries for god mode responses |\n\n### 3. Debugging Process\n\n```python\n# 1. Check if directives exist\ncustom_state = game_state.get('custom_campaign_state', {})\ndirectives = custom_state.get('god_mode_directives', [])\nprint(f\"Saved directives: {len(directives)}\")\n\n# 2. Find god mode story entries\nstory_ref = campaign_ref.collection('story')\nfor entry in story_ref.order_by('timestamp', direction='DESCENDING').limit(100).stream():\n    data = entry.to_dict()\n    if data.get('actor') == 'gemini' and 'God Mode active' in data.get('text', ''):\n        debug_info = data.get('debug_info', {})\n        raw_response = debug_info.get('raw_response_text', '')\n        if raw_response:\n            parsed = json.loads(raw_response)\n            print(f\"Entry {entry.id}:\")\n            print(f\"  Has directives field: {'directives' in parsed}\")\n            if 'directives' not in parsed:\n                print(f\"  State updates: {parsed.get('state_updates', {})}\")\n```\n\n### 4. Key Insight: `dm_notes` vs `directives`\n\n- **`dm_notes`**: Internal notes stored in `state_updates.debug_info.dm_notes`. ARE injected into future system prompts (as of this PR) to provide important context the LLM wrote but did not formally save as directives.\n- **`directives`**: Persisted rules stored in `god_mode_directives[]`. ARE injected into system prompts via `agent_prompts.py:669-753`.\n\nIf the LLM writes to `dm_notes` instead of `directives`, the rule won't persist as a formal directive.\n\n## User Identification\n- Users are identified by **Firebase Auth UID**, NOT email\n- Primary user: `\u003Cauthorized-user-email>` → UID: `\u003Cfirebase-auth-uid>`\n- Test user: `\u003Cdedicated-non-primary-test-account-email>`\n- Use `auth.get_user_by_email()` to convert email → UID\n\n## Prerequisites\n\n### Environment Variables\n```bash\nexport WORLDAI_DEV_MODE=true\nexport WORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"\u003Cpath-to-service-account-key>\"\n```\n\n### Service Account Key\nLocation: a machine-local service account key file (never committed); point\n`WORLDAI_GOOGLE_APPLICATION_CREDENTIALS` at it.\nProject: `$FIREBASE_PROJECT_ID` (required)\n\n## Using campaign_manager.py\n\nThe recommended tool for production queries is `scripts\u002Fcampaign_manager.py`.\n\n### Find User by Email\n```bash\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fcampaign_manager.py find-user user@example.com\n```\n\n### Analyze User Activity (with token\u002Fcost estimation)\n```bash\n# Analyze last 3 months\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fcampaign_manager.py analytics user@example.com\n\n# Specific month\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fcampaign_manager.py analytics user@example.com --month YYYY-MM\n```\n\n### Query Campaigns by Name\n```bash\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fcampaign_manager.py query \u003CUID> \"Campaign Name\"\n```\n\n## Direct Python Query (Ad-hoc)\n\nFor custom queries, use this pattern:\n\n```python\nimport sys\nsys.path.insert(0, 'mvp_site')\n\n# CRITICAL: Apply clock skew patch BEFORE importing Firebase\nfrom mvp_site.clock_skew_credentials import apply_clock_skew_patch\napply_clock_skew_patch()\n\nimport firebase_admin\nfrom firebase_admin import auth, firestore, credentials\nimport os\n\n# Initialize with explicit credentials\nif firebase_admin._apps:\n    firebase_admin.delete_app(firebase_admin.get_app())\n\ncred = credentials.Certificate(os.environ['WORLDAI_GOOGLE_APPLICATION_CREDENTIALS'])\nfirebase_admin.initialize_app(cred)\ndb = firestore.client()\n\n# Find user by email\nemail = 'user@example.invalid'\nuser_record = auth.get_user_by_email(email)\nuid = user_record.uid\n\n# Get campaigns\ncampaigns_ref = db.collection('users').document(uid).collection('campaigns')\nfor campaign in campaigns_ref.stream():\n    data = campaign.to_dict()\n    print(f\"{campaign.id}: {data.get('title')}\")\n\n    # Get story entries\n    story_ref = campaigns_ref.document(campaign.id).collection('story')\n    entry_count = sum(1 for _ in story_ref.stream())\n    print(f\"  Entries: {entry_count}\")\n```\n\n## Token\u002FCost Estimation Constants\n\nFrom `$PROJECT_ROOT\u002Fllm_service.py`:\n- **Base system instructions:** ~43,000 tokens\n- **World content estimate:** ~50,000 tokens\n- **Tokens per story entry:** ~500 tokens\n- **Max history turns:** 100 (truncation limit)\n- **200K threshold:** Above this = \"long context\" pricing (2x cost)\n\n### Gemini 3 Flash Pricing\n| Context Size | Input | Output |\n|--------------|-------|--------|\n| ≤200K tokens | $0.50\u002FM | $3\u002FM |\n| >200K tokens | $1.00\u002FM | $6\u002FM |\n\n## Common Issues\n\n### Clock Skew Error\n```\nInvalid JWT: Token must be a short-lived token (60 minutes)\n```\n**Solution:** Ensure `apply_clock_skew_patch()` is called BEFORE importing Firebase.\n\n### Auth Provider Not Found\n```\nNo auth provider found for the given identifier\n```\n**Solution:** Use explicit credentials with `credentials.Certificate()`.\n\n### Empty User List\nIf `firebase_user_analytics.py` shows only test users, you're likely missing real production users because:\n1. The script was limiting to first 10 users\n2. Real users have Firebase Auth UIDs, not test IDs like `test-user-123`\n\n**Solution:** Use `campaign_manager.py analytics` with a known email address.\n\n## Related Scripts\n- `scripts\u002Fcampaign_manager.py` - Main production query tool\n- `scripts\u002Ffirebase_user_analytics.py` - User behavior analytics\n- `scripts\u002FCLAUDE.md` - Script documentation\n","# Firebase Production Campaign Database Access\n\n## Overview\nThis skill documents how to query the **production Firestore database** for Your Project campaigns and user data.\n\n## CRITICAL: Campaign Lookup\n\n**Campaigns are NESTED under users, NOT at root level!**\n\n```python\n# WRONG - This queries the wrong collection (test data only):\ndb.collection('campaigns').document('CAMPAIGN_ID')\n\n# CORRECT - Campaigns are nested under user UID:\ndb.collection('users').document(uid).collection('campaigns').document('CAMPAIGN_ID')\n```\n\n### Quick Lookup for Known Campaign ID\n```python\n# 1. Get user UID from the supplied email\nuser_record = auth.get_user_by_email('user@example.invalid')\nuid = user_record.uid\n\n# 2. Query nested path\ndoc = db.collection('users').document(uid).collection('campaigns').document('CAMPAIGN_ID').get()\n```\n\n## Database Structure\n\n```\nFirestore Database: $FIREBASE_PROJECT_ID\n├── campaigns\u002F                    # ← WRONG: Only test data here (5 campaigns)\n│   └── {test_campaign_id}\u002F\n│\n└── users\u002F                        # ← CORRECT: Real user data here (146+ campaigns)\n    └── {Firebase_Auth_UID}\u002F      # e.g., \u003Cfirebase-auth-uid>\n        └── campaigns\u002F\n            └── {campaign_id}\u002F    # e.g., \u003Ccampaign-id>\n                ├── title         # \"Example campaign\"\n                ├── created_at\n                ├── last_played\n                ├── world_name\n                ├── game_states\u002F              # ← SUBCOLLECTION for game state\n                │   └── current_state\u002F        # Main game state document\n                │       ├── player_character_data\n                │       ├── combat_state\n                │       ├── npc_data\n                │       └── custom_campaign_state\u002F\n                │           └── god_mode_directives[]  # ← Persisted rules\n                └── story\u002F\n                    └── {entry_id}\u002F\n                        ├── actor (user\u002Fgemini)\n                        ├── text\n                        └── timestamp\n```\n\n## IMPORTANT: Game State Location\n\n**Game state is in a SUBCOLLECTION, not a field!**\n\n```python\n# WRONG - game_state is NOT a field on the campaign document:\ncampaign = db.collection('users').document(uid).collection('campaigns').document(campaign_id).get()\ngame_state = campaign.to_dict().get('game_state')  # Returns empty!\n\n# CORRECT - game_state is in a subcollection called 'game_states':\ngame_state_ref = db.collection('users').document(uid).collection('campaigns').document(campaign_id).collection('game_states').document('current_state')\ngame_state = game_state_ref.get().to_dict()\n```\n\n### Querying God Mode Directives\n\n```python\n# Get god mode directives for a campaign\ngame_state_ref = campaign_ref.collection('game_states').document('current_state')\ngame_state = game_state_ref.get().to_dict()\n\ncustom_campaign_state = game_state.get('custom_campaign_state', {})\ngod_mode_directives = custom_campaign_state.get('god_mode_directives', [])\n\nfor directive in god_mode_directives:\n    if isinstance(directive, dict):\n        print(f\"Rule: {directive.get('rule')}\")\n        print(f\"Added: {directive.get('added')}\")\n```\n\n### Using the Directive Query Script\n\n```bash\n# List all directives for a campaign\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fquery_directives.py CAMPAIGN_ID\n\n# Debug why a directive wasn't saved\npython scripts\u002Fquery_directives.py CAMPAIGN_ID --debug-missing \"power scaling\"\n\n# Manually add a missing directive\npython scripts\u002Fquery_directives.py CAMPAIGN_ID --email \"user@example.com\" --add \"Level 9 is extremely powerful - never use 'mere' or 'modest'\"\n```\n\n## Debugging Missing God Mode Directives\n\nWhen a user's god mode request doesn't result in a saved directive, follow this process:\n\n### 1. How Directives Are Saved\n\nThe LLM must return a `directives` field in its structured JSON response:\n\n```json\n{\n    \"god_mode_response\": \"Acknowledged...\",\n    \"directives\": {\n        \"add\": [\"Rule to remember going forward\"],\n        \"drop\": [\"Rule to stop following\"]\n    }\n}\n```\n\n**Processing code:** `$PROJECT_ROOT\u002Fworld_logic.py:1585-1667`\n**Prompt instructions:** `$PROJECT_ROOT\u002Fprompts\u002Fgod_mode_instruction.md:72-96`\n\n### 2. Common Failure Modes\n\n| Symptom | Cause | Solution |\n|---------|-------|----------|\n| Directive acknowledged but not saved | LLM returned `god_mode_response` but no `directives.add` | Check raw LLM response |\n| Directive in `dm_notes` only | LLM put rule in `state_updates.debug_info.dm_notes` | `dm_notes` are now injected into future prompts as part of the system prompt |\n| Empty `god_mode_directives` list | No directives ever saved | Check story entries for god mode responses |\n\n### 3. Debugging Process\n\n```python\n# 1. Check if directives exist\ncustom_state = game_state.get('custom_campaign_state', {})\ndirectives = custom_state.get('god_mode_directives', [])\nprint(f\"Saved directives: {len(directives)}\")\n\n# 2. Find god mode story entries\nstory_ref = campaign_ref.collection('story')\nfor entry in story_ref.order_by('timestamp', direction='DESCENDING').limit(100).stream():\n    data = entry.to_dict()\n    if data.get('actor') == 'gemini' and 'God Mode active' in data.get('text', ''):\n        debug_info = data.get('debug_info', {})\n        raw_response = debug_info.get('raw_response_text', '')\n        if raw_response:\n            parsed = json.loads(raw_response)\n            print(f\"Entry {entry.id}:\")\n            print(f\"  Has directives field: {'directives' in parsed}\")\n            if 'directives' not in parsed:\n                print(f\"  State updates: {parsed.get('state_updates', {})}\")\n```\n\n### 4. Key Insight: `dm_notes` vs `directives`\n\n- **`dm_notes`**: Internal notes stored in `state_updates.debug_info.dm_notes`. ARE injected into future system prompts (as of this PR) to provide important context the LLM wrote but did not formally save as directives.\n- **`directives`**: Persisted rules stored in `god_mode_directives[]`. ARE injected into system prompts via `agent_prompts.py:669-753`.\n\nIf the LLM writes to `dm_notes` instead of `directives`, the rule won't persist as a formal directive.\n\n## User Identification\n- Users are identified by **Firebase Auth UID**, NOT email\n- Primary user: `\u003Cauthorized-user-email>` → UID: `\u003Cfirebase-auth-uid>`\n- Test user: `\u003Cdedicated-non-primary-test-account-email>`\n- Use `auth.get_user_by_email()` to convert email → UID\n\n## Prerequisites\n\n### Environment Variables\n```bash\nexport WORLDAI_DEV_MODE=true\nexport WORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"\u003Cpath-to-service-account-key>\"\n```\n\n### Service Account Key\nLocation: a machine-local service account key file (never committed); point\n`WORLDAI_GOOGLE_APPLICATION_CREDENTIALS` at it.\nProject: `$FIREBASE_PROJECT_ID` (required)\n\n## Using campaign_manager.py\n\nThe recommended tool for production queries is `scripts\u002Fcampaign_manager.py`.\n\n### Find User by Email\n```bash\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fcampaign_manager.py find-user user@example.com\n```\n\n### Analyze User Activity (with token\u002Fcost estimation)\n```bash\n# Analyze last 3 months\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fcampaign_manager.py analytics user@example.com\n\n# Specific month\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fcampaign_manager.py analytics user@example.com --month YYYY-MM\n```\n\n### Query Campaigns by Name\n```bash\nWORLDAI_DEV_MODE=true \\\nWORLDAI_GOOGLE_APPLICATION_CREDENTIALS=\"$WORLDAI_GOOGLE_APPLICATION_CREDENTIALS\" \\\npython scripts\u002Fcampaign_manager.py query \u003CUID> \"Campaign Name\"\n```\n\n## Direct Python Query (Ad-hoc)\n\nFor custom queries, use this pattern:\n\n```python\nimport sys\nsys.path.insert(0, 'mvp_site')\n\n# CRITICAL: Apply clock skew patch BEFORE importing Firebase\nfrom mvp_site.clock_skew_credentials import apply_clock_skew_patch\napply_clock_skew_patch()\n\nimport firebase_admin\nfrom firebase_admin import auth, firestore, credentials\nimport os\n\n# Initialize with explicit credentials\nif firebase_admin._apps:\n    firebase_admin.delete_app(firebase_admin.get_app())\n\ncred = credentials.Certificate(os.environ['WORLDAI_GOOGLE_APPLICATION_CREDENTIALS'])\nfirebase_admin.initialize_app(cred)\ndb = firestore.client()\n\n# Find user by email\nemail = 'user@example.invalid'\nuser_record = auth.get_user_by_email(email)\nuid = user_record.uid\n\n# Get campaigns\ncampaigns_ref = db.collection('users').document(uid).collection('campaigns')\nfor campaign in campaigns_ref.stream():\n    data = campaign.to_dict()\n    print(f\"{campaign.id}: {data.get('title')}\")\n\n    # Get story entries\n    story_ref = campaigns_ref.document(campaign.id).collection('story')\n    entry_count = sum(1 for _ in story_ref.stream())\n    print(f\"  Entries: {entry_count}\")\n```\n\n## Token\u002FCost Estimation Constants\n\nFrom `$PROJECT_ROOT\u002Fllm_service.py`:\n- **Base system instructions:** ~43,000 tokens\n- **World content estimate:** ~50,000 tokens\n- **Tokens per story entry:** ~500 tokens\n- **Max history turns:** 100 (truncation limit)\n- **200K threshold:** Above this = \"long context\" pricing (2x cost)\n\n### Gemini 3 Flash Pricing\n| Context Size | Input | Output |\n|--------------|-------|--------|\n| ≤200K tokens | $0.50\u002FM | $3\u002FM |\n| >200K tokens | $1.00\u002FM | $6\u002FM |\n\n## Common Issues\n\n### Clock Skew Error\n```\nInvalid JWT: Token must be a short-lived token (60 minutes)\n```\n**Solution:** Ensure `apply_clock_skew_patch()` is called BEFORE importing Firebase.\n\n### Auth Provider Not Found\n```\nNo auth provider found for the given identifier\n```\n**Solution:** Use explicit credentials with `credentials.Certificate()`.\n\n### Empty User List\nIf `firebase_user_analytics.py` shows only test users, you're likely missing real production users because:\n1. The script was limiting to first 10 users\n2. Real users have Firebase Auth UIDs, not test IDs like `test-user-123`\n\n**Solution:** Use `campaign_manager.py analytics` with a known email address.\n\n## Related Scripts\n- `scripts\u002Fcampaign_manager.py` - Main production query tool\n- `scripts\u002Ffirebase_user_analytics.py` - User behavior analytics\n- `scripts\u002FCLAUDE.md` - Script documentation\n",{"name":5,"description":7},"main","8144f00ebafc4306264c63239e4b9fa42e48a90e","plugins\u002Fworldarchitect\u002Fskills\u002Ffirebase-prod-campaigns",0,"https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills","https:\u002F\u002Fgithub.com\u002Fjleechanorg","2026-11-14 14:55:35",{"source":8,"skillName":5,"commands":44,"prompt":54,"zipAvailable":55},[45,48,51],{"tool":46,"command":47},"npx","npx skills add jleechanorg\u002Fjleechan-skills --skill firebase-prod-campaigns",{"tool":49,"command":50},"bunx","bunx skills add jleechanorg\u002Fjleechan-skills --skill firebase-prod-campaigns",{"tool":52,"command":53},"pnpm","pnpm dlx skills add jleechanorg\u002Fjleechan-skills --skill firebase-prod-campaigns","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fworldarchitect\u002Fskills\u002Ffirebase-prod-campaigns\u002FSKILL.md",true,[],[58,66,73,81,89,98],{"skillNo":59,"name":60,"nameZh":6,"description":61,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":62,"categories":63,"keywords":64,"publishedAt":65},"01M7DRVZXXMGY4G81K5GVF4V20","disk-reclaim-playbook","Use Disk Magician to diagnose disk growth or qualify cleanup on macOS or Linux.","https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fdisk-reclaim-playbook\u002FSKILL.md",[],[],"2026-11-15 14:19:17",{"skillNo":67,"name":68,"nameZh":6,"description":69,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":70,"categories":71,"keywords":72,"publishedAt":65},"01M7B63PNTT2TY78RFKHD8SP3X","claudea-bench","Compare `claudea` and normal `claude` on a fair split of comparable work by default; use `--strict` for duplicate runs of the exact same task.","https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fclaudea-bench\u002FSKILL.md",[],[],{"skillNo":74,"name":75,"nameZh":6,"description":76,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":77,"categories":78,"keywords":79,"publishedAt":80},"01M7622KQJ32AV4K5BXEMVSSEB","pr","Alias for the canonical pr-lifecycle PR workflow skill (\u002Fpr-workflow, \u002Fprw).","https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fpr\u002FSKILL.md",[],[],"2026-11-12 13:55:43",{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":88},"01M7432W92AKC4D1TKJ00VCMMT","whisper","OpenAI's general-purpose speech recognition model. Supports 99 languages, transcription, translation to English, and language identification. Six model sizes from tiny (39M params) to large (1550M params). Use for speech-to-text, podcast transcription, or multilingual audio processing. Best for robust, multilingual ASR.","https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002F.claude\u002Fskills_archive\u002F2026-11-09-no-usage-evidence\u002Fwhisper\u002FSKILL.md",[],[],"2026-11-11 15:11:14",{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":93,"licenseFileUrl":94,"sourceHtmlUrl":95,"categories":96,"keywords":97,"publishedAt":88},"01M7432T6BN1A9SHB8RBQR5EMP","webapp-testing","Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002F.claude\u002Fskills_archive\u002F2026-11-09-no-usage-evidence\u002Fwebapp-testing\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002F.claude\u002Fskills_archive\u002F2026-11-09-no-usage-evidence\u002Fwebapp-testing\u002FSKILL.md",[],[],{"skillNo":99,"name":100,"nameZh":6,"description":101,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":102,"categories":103,"keywords":104,"publishedAt":88},"01M7432NDC7S6C6MX7M6RW8CTT","pr-report","This skill should be used when the user asks for a PR report, PR audit, PR delta analysis, \u002Fpr-report, or wants per-PR summary with delta files\u002Flines. Generates a structured report for one or more open PRs covering purpose, files changed, +\u002F− line counts, \u002Fcode-standards + \u002Fthermo review findings, \u002Fponytail simplification opportunities, file-overlap combination candidates, and \u002Fgreen status per pr-green-definition. Output: machine-readable JSONL + human-readable markdown. Read-only by default; can apply simplifications if user opts in.","https:\u002F\u002Fgithub.com\u002Fjleechanorg\u002Fjleechan-skills\u002Fblob\u002Fmain\u002F.claude\u002Fskills_archive\u002F2026-11-09-no-usage-evidence\u002Fpr-report\u002FSKILL.md",[],[]]