agentleFS
MicrosoftKnown publishermicrosoft/fabric-apps-analytic-templates/.agents/skills/analytics/SKILL.md

analytics

Skill31 starsChanged 16 days agoMITView on GitHub

Read Power BI semantic-model data through Rayfin connectors. Use the semantic-model query hook with normalized errors, validated DAX and exact output columns, then shape results for charts and grids.

85 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use free-tools, co-marketing and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • CesarjoquinSkill

    free-tools

    When the user wants to plan, evaluate, or build a free tool for marketing purposes — lead generation, SEO value, or brand awareness. Also use when the user mentions "engineering as marketing," "free tool," "marketing tool," "calculator," "generator," "interactive tool," "lead gen tool," "build a tool for leads," "free resource," "ROI calculator," "grader tool," "audit tool," "should I build a free tool," or "tools for lead gen." Use this whenever someone wants to build something useful and give it away to attract leads or earn links. For downloadable content lead magnets (ebooks, checklists, templates), see lead-magnets.

    Also in 29 projects that use this

  • CesarjoquinSkill

    co-marketing

    When the user wants to find co-marketing partners, plan joint campaigns, or brainstorm partnership opportunities. Use when the user says 'co-marketing,' 'partner marketing,' 'joint campaign,' 'who should we partner with,' 'integration marketing,' 'cross-promotion,' 'collaborate with another company,' 'partnership ideas,' or 'co-brand.' For customer referral programs, see referrals. For launch-specific partnerships, see launch.

    Also in 29 projects that use this

  • coreyhaines31Skill

    marketing-council

    When the user wants several expert takes on a marketing decision, or asks what a famous marketer would say about it: a simulated board (Seth Godin, David Ogilvy, April Dunford, Byron Sharp, and more), each grounded in their documented frameworks, where they disagree, and a recommendation. To execute, hand off to the relevant skill.

    Also in 22 projects that use this

  • ukunal91appSkill

    community-marketing

    Build and leverage online communities to drive product growth and brand loyalty. Use when the user wants to create a community strategy, grow a Discord or Slack community, manage a forum or subreddit, build brand advocates, increase word-of-mouth, drive community-led growth, engage users post-signup, or turn customers into evangelists. Trigger phrases: "build a community," "community strategy," "Discord community," "Slack community," "community-led growth," "brand advocates," "user community," "forum strategy," "community engagement," "grow our community," "ambassador program," "community flywheel.

    Also in 31 projects that use this

  • coreyhaines31Skill

    marketing-loops

    When the user wants a recurring marketing job an AI agent runs on a cadence or trigger, or asks what a weekly or daily automated check should do, remember, and when it should stop: SEO and ads checks, churn watches, outbound triage. For one-off ideas, see marketing-ideas. For the test loop, see ab-testing.

    Also in 13 projects that use this

  • roerohanSkill

    emails

    When the user wants to create or optimize an email sequence, drip campaign, automated email flow, or lifecycle email program. Also use when the user mentions "email sequence," "drip campaign," "nurture sequence," "onboarding emails," "welcome sequence," "re-engagement emails," "email automation," "lifecycle emails," "trigger-based emails," "email funnel," "email workflow," "what emails should I send," "welcome series," or "email cadence." Use this for any multi-email automated flow. For cold outreach emails, see cold-email. For in-app onboarding, see onboarding.

    Also in 26 projects that use this

  • +5 more from Cesarjoquin

The file

Show its rules and text

We split this skill into the rules it gives an agent

14 rules. 0 are common, 6 are distinctive, and 8 are very specific to this project.

  • 0

    Common

    Most of the 72 edited versions we read keep these.

  • 6

    Distinctive

    This author's own choices. Worth a look.

  • 8

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use ids from a Fabric URL or search results.

    line 15
  2. Very specific:

    Follow the DAX validation gate before implementing UI that depends on a query's results.

    line 35
  3. Distinctive:

    Follow the consuming app's instructions for discovery/source-reading order, UI sequencing, runtime client setup and cache policy.

    line 38
  4. Very specific:

    Use the shipped useSemanticModelQuery hook.

    line 43
  5. Very specific:

    No error result contains a partial table.

    line 72
  6. Distinctive:

    Follow the shared visual-interactivity skill for default semantic-model coordination, manager configuration, source binding, query-factory …

    line 79
  7. Very specific:

    Use one EVALUATE per query and aggregate or TOPN to bound result size.

    line 86
  8. Distinctive:

    Only for genuine numeric overflow, use text, scale the value, or convert to DOUBLE if the precision change is acceptable.

    line 93
  9. Very specific:

    Use exact raw returned column names as columnMetadata keys (Calendar[Year], [Sales]).

    line 97
  10. Very specific:

    Do not branch on wire dataType, which may be "unknown", to choose display formatting.

    line 99
  11. Distinctive:

    Never mutate a result; copy before sorting.

    line 101
  12. Very specific:

    Keep query factories and .dax/.json files together under frontend-relative src/queries/<page>/, with kebab-case names and group/root barrel …

    line 103
  13. Very specific:

    Import DAX using ?raw; do not inline it in components.

    line 105
  14. Distinctive:

    Read visuals for rendering and app-design for template-owned presentation policies.

    line 106

“Common” is measured: kept by at least 6 in 10 of the 72 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Analytics — reading a semantic model

Connector and discovery

Connect only to a published Power BI semantic model; local .pbix files are not supported. Never guess ids or add a source without the user's consent. Use ids from a Fabric URL or search results. Registration requires sign-in:

npx rayfin connector search "<name>" --type fabric-semanticmodel --all-workspaces --json
npx rayfin connector add --type fabric-semanticmodel --name <alias> --workspace-id <workspaceId> --item-id <itemId>

For My workspace use me. A 401 GroupNotAccessible after successful search means missing query access, not necessarily an expired session: check npx rayfin login status before signing in again.

The CLI owns connector registration and generated runtime maps. Do not hand-wire them or replace the template's auth/client bootstrap. The browser sends the query and connector name, never workspace/item ids.

The first schema-discovery catalog query is the connectivity preflight; do not run a separate connector probe. Discovery is always available through fabric-app-semantic-model-tools query-schema. Use dax-authoring and query-design together for query work. Follow the DAX validation gate before implementing UI that depends on a query's results. Execute final queries through fabric-app-semantic-model-tools run-dax-query. Follow the consuming app's instructions for discovery/source-reading order, UI sequencing, runtime client setup and cache policy.

Runtime contract

Use the shipped useSemanticModelQuery hook. Call hooks unconditionally before loading/error returns. Check error, then require data.status === "success" before accessing tables. Query and transport failures are normalized into data.status === "error" and mirrored onto error; unexpected internal failures may set only error.

For coordinated semantic-model visuals, use useQueryFactoryTarget instead; see Managed semantic-model interactions.

const { data, isLoading, error, refetch } = useSemanticModelQuery({
    connection: "sales",
    query,
});
if (error) return <p role="alert">{error.message}</p>;
if (isLoading && !data) return <p>Loading…</p>;
if (data?.status !== "success") return null;
const table = toDataTable(data.table, columnMetadata);
CategoryMeaningResponse
queryPower BI rejected DAXFix the query
overflowNumeric value cannot fit a JS numberInspect precision, not row count
networkNo response (offline, DNS, CORS)Retry
apiService answered with failureCheck auth/access
unknownOther failuresRead the diagnostics

Preserve category, code, Fabric workload, and original cause. No error result contains a partial table. refetch() runs the query again. Empty connection/query inputs leave the hook idle. getRayfinClient() may be synchronous or asynchronous depending on the template: await it before using .connectors outside the hook.

Managed semantic-model interactions

Follow the shared visual-interactivity skill for default semantic-model coordination, manager configuration, source binding, query-factory targets, cross-highlighting and retained-data error handling. That skill owns interaction policy; the consuming template owns runtime caching.

Rows and field names

Use one EVALUATE per query and aggregate or TOPN to bound result size. resultSetRowCountLimit silently truncates without a completeness flag; a result exactly at the cap is possibly incomplete. The hook does not forward that option. Too many rows is not numeric overflow.

Overflow means an Int64 beyond ±9,007,199,254,740,991 or a fixed-decimal value whose unscaled digits exceed that limit (roughly ±900 billion at four decimals). Only for genuine numeric overflow, use text, scale the value, or convert to DOUBLE if the precision change is acceptable. Never reshape a stored measure to work around a decoder bug; a conversion can drop mixed text/numeric branches.

Use exact raw returned column names as columnMetadata keys (Calendar[Year], [Sales]). Supply bracket-free name aliases, display names and model formats. Do not branch on wire dataType, which may be "unknown", to choose display formatting. Missing first-row fields can yield missing inferred columns. Never mutate a result; copy before sorting.

Keep query factories and .dax/.json files together under frontend-relative src/queries/<page>/, with kebab-case names and group/root barrel exports. Import DAX using ?raw; do not inline it in components. Read visuals for rendering and app-design for template-owned presentation policies.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.