tn-financial-data 0.1.4 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -37,7 +37,7 @@ This package is the hosted agent-facing surface only. The repo's website, local
37
37
  npm install -g tn-financial-data
38
38
 
39
39
  export TN_FINANCIAL_DATA_API_KEY=<your-api-key>
40
- tn-financial-data query available-tickers
40
+ tn-financial-data query resolve-ticker --query google
41
41
  ```
42
42
 
43
43
  Live reads accept:
@@ -51,6 +51,8 @@ Optional base URL override:
51
51
  - `TN_FINANCIAL_DATA_API_BASE_URL`
52
52
 
53
53
  The published CLI reads those values from the current process environment only.
54
+ Use `resolve-ticker` to map company or brand input to supported symbols.
55
+ Treat `available-tickers` as the authoritative support list for exact symbols; do not silently swap an unsupported exact ticker to a different share class.
54
56
 
55
57
  Production default:
56
58
 
@@ -61,6 +63,7 @@ https://api.truenorth-financial.ai/v1
61
63
  ## Quick Start
62
64
 
63
65
  ```bash
66
+ tn-financial-data query resolve-ticker --query google
64
67
  tn-financial-data query available-tickers
65
68
  tn-financial-data query company --ticker AAPL
66
69
  tn-financial-data query filings --ticker AAPL --filing-type 8-K --limit 5
@@ -169,8 +172,11 @@ const client = new TnFinancialData({
169
172
  apiKey: process.env.TN_FINANCIAL_DATA_API_KEY!,
170
173
  });
171
174
 
175
+ const resolution = await client.resolveTicker("google");
176
+ console.log(resolution.status, resolution.resolved_ticker);
177
+
172
178
  const filings = await client.getFilings("AAPL", {
173
- filingType: ["8-K"],
179
+ filingTypes: ["8-K"],
174
180
  limit: 3,
175
181
  });
176
182
 
@@ -179,7 +185,7 @@ console.log(filings.filings[0]?.accession_number);
179
185
  const filingItems = await client.getFilingItems("AAPL", {
180
186
  accessionNumber: "0000320193-26-000005",
181
187
  filingType: "8-K",
182
- item: ["2.02"],
188
+ items: ["2.02"],
183
189
  includeExhibits: true,
184
190
  });
185
191
 
package/dist/cli.js CHANGED
@@ -230,6 +230,11 @@ var TnFinancialData = class {
230
230
  async getAvailableTickers() {
231
231
  return this.request("/financials/income-statements/tickers");
232
232
  }
233
+ async resolveTicker(query) {
234
+ return this.request(
235
+ `/tickers/resolve?${new URLSearchParams({ q: query })}`
236
+ );
237
+ }
233
238
  async getPrices(ticker, opts) {
234
239
  const params = new URLSearchParams({
235
240
  ticker,
@@ -568,13 +573,14 @@ function rootHelp() {
568
573
  "tn-financial-data",
569
574
  "",
570
575
  "Usage:",
571
- " tn-financial-data query <available-tickers|company|filings|filing-items|general-overview|financials|financial-metrics|financial-metrics-snapshot|earnings|quarterly-highlights|analyst-estimates|prices|snapshot|news|insider-trades|institutional-ownership|investor-portfolio|global-rates|segmented-revenues|screen|screen-fields> [options]",
576
+ " tn-financial-data query <available-tickers|resolve-ticker|company|filings|filing-items|general-overview|financials|financial-metrics|financial-metrics-snapshot|earnings|quarterly-highlights|analyst-estimates|prices|snapshot|news|insider-trades|institutional-ownership|investor-portfolio|global-rates|segmented-revenues|screen|screen-fields> [options]",
572
577
  " tn-financial-data skill <install|print|targets> [--tool claude|opencode]",
573
578
  " tn-financial-data describe opencli",
574
579
  " tn-financial-data --version",
575
580
  "",
576
581
  "Examples:",
577
582
  " tn-financial-data query available-tickers",
583
+ ' tn-financial-data query resolve-ticker --query "google"',
578
584
  " tn-financial-data query financials --ticker AAPL --period annual --statement all",
579
585
  " tn-financial-data query filings --ticker AAPL --filing-type 8-K --limit 10",
580
586
  " tn-financial-data query filing-items --ticker AAPL --accession-number 0000320193-26-000005 --full-text",
@@ -608,6 +614,7 @@ function queryHelp() {
608
614
  return [
609
615
  "Usage:",
610
616
  " tn-financial-data query available-tickers [--api-key <key>] [--base-url <url>]",
617
+ " tn-financial-data query resolve-ticker --query <text> [--api-key <key>] [--base-url <url>]",
611
618
  " tn-financial-data query company --ticker <symbol> [--api-key <key>] [--base-url <url>]",
612
619
  " tn-financial-data query filings --ticker <symbol> [--filing-type <csv>] [--start-date <date>] [--end-date <date>] [--limit <n>] [--api-key <key>] [--base-url <url>]",
613
620
  " tn-financial-data query filing-items --ticker <symbol> --accession-number <accession> [--filing-type <10-K|10-Q|8-K>] [--item <csv>] [--full-text] [--include-exhibits] [--api-key <key>] [--base-url <url>]",
@@ -728,6 +735,7 @@ function buildOpenCliDocument() {
728
735
  ],
729
736
  examples: [
730
737
  "tn-financial-data query available-tickers",
738
+ 'tn-financial-data query resolve-ticker --query "google"',
731
739
  "tn-financial-data query filings --ticker AAPL --filing-type 8-K --limit 10",
732
740
  "tn-financial-data query filing-items --ticker AAPL --accession-number 0000320193-26-000005 --full-text",
733
741
  "tn-financial-data query general-overview --ticker AAPL --period quarterly --financial-limit 4 --news-limit 5",
@@ -785,6 +793,24 @@ function buildOpenCliDocument() {
785
793
  name: "available-tickers",
786
794
  description: "Fetch the current supported ticker snapshot with financial and news freshness timestamps."
787
795
  },
796
+ {
797
+ name: "resolve-ticker",
798
+ description: "Resolve a company keyword or exact symbol against the supported ticker universe without silently swapping share classes.",
799
+ options: [
800
+ {
801
+ name: "query",
802
+ required: true,
803
+ arguments: [
804
+ {
805
+ name: "text",
806
+ required: true,
807
+ description: "Company name, brand, prompt fragment, or ticker text."
808
+ }
809
+ ],
810
+ description: "Query text to resolve."
811
+ }
812
+ ]
813
+ },
788
814
  {
789
815
  name: "company",
790
816
  description: "Fetch company facts for a single ticker.",
@@ -1675,6 +1701,18 @@ var QUERY_SUBCOMMAND_HELP = {
1675
1701
  ],
1676
1702
  "tn-financial-data query available-tickers"
1677
1703
  ),
1704
+ "resolve-ticker": renderHelp(
1705
+ "resolve-ticker",
1706
+ [
1707
+ "Resolve a company keyword or exact symbol against the supported ticker universe without silently swapping share classes."
1708
+ ],
1709
+ [
1710
+ "--query <text> Required. Company name, brand, prompt fragment, or ticker text.",
1711
+ "--api-key <key> API key. Overrides TN_FINANCIAL_DATA_API_KEY.",
1712
+ "--base-url <url> API base URL override."
1713
+ ],
1714
+ 'tn-financial-data query resolve-ticker --query "google"'
1715
+ ),
1678
1716
  company: renderHelp(
1679
1717
  "company",
1680
1718
  ["Fetch the basic company identity record for a single ticker."],
@@ -2064,6 +2102,11 @@ async function handleQuery(parsed, runtime, deps) {
2064
2102
  case "available-tickers":
2065
2103
  printJson(runtime, await client.getAvailableTickers());
2066
2104
  return 0;
2105
+ case "resolve-ticker": {
2106
+ const query = requireOption(parsed, "query");
2107
+ printJson(runtime, await client.resolveTicker(query));
2108
+ return 0;
2109
+ }
2067
2110
  case "company": {
2068
2111
  const ticker = requireOption(parsed, "ticker");
2069
2112
  printJson(runtime, await client.getCompanyFacts(ticker));
@@ -498,6 +498,33 @@ interface AvailableTickersResponse {
498
498
  as_of: string | null;
499
499
  tickers: AvailableTicker[];
500
500
  }
501
+ type TickerResolutionStatus = "exact_supported" | "resolved" | "ambiguous" | "exact_unsupported" | "none";
502
+ type TickerResolutionIntent = "ticker" | "keyword";
503
+ type TickerResolutionMatchKind = "ticker_exact" | "ticker_format" | "alias_exact" | "company_name" | "company_prefix" | "company_tokens";
504
+ type TickerResolutionRelationship = "supported" | "format_alias" | "brand_alias" | "deprecated_symbol" | "same_issuer_other_share_class";
505
+ type TickerResolutionConfidence = "high" | "medium" | "low";
506
+ interface TickerResolutionCandidate {
507
+ ticker: string;
508
+ name: string;
509
+ financials_updated_at: string | null;
510
+ news_updated_at: string | null;
511
+ updated_at: string;
512
+ match_kind: TickerResolutionMatchKind;
513
+ relationship: TickerResolutionRelationship;
514
+ confidence: TickerResolutionConfidence;
515
+ matched_alias: string | null;
516
+ }
517
+ interface TickerResolutionResponse {
518
+ query: string;
519
+ normalized_query: string;
520
+ intent: TickerResolutionIntent;
521
+ as_of: string | null;
522
+ extracted_query?: string;
523
+ status: TickerResolutionStatus;
524
+ resolved_ticker: string | null;
525
+ resolved_name: string | null;
526
+ candidates: TickerResolutionCandidate[];
527
+ }
501
528
  interface PriceHistoryResponse extends ReadMetadata {
502
529
  interval: PriceInterval;
503
530
  prices: PriceBar[];
@@ -812,6 +839,7 @@ declare class TnFinancialData {
812
839
  getGeneralOverview(ticker: string, opts?: GeneralOverviewOpts): Promise<ApiResponse<GeneralOverviewResponse>>;
813
840
  getKeyStatistics(ticker: string): Promise<ApiResponse<KeyStatisticsResponse>>;
814
841
  getAvailableTickers(): Promise<ApiResponse<AvailableTickersResponse>>;
842
+ resolveTicker(query: string): Promise<ApiResponse<TickerResolutionResponse>>;
815
843
  getPrices(ticker: string, opts: PriceOpts): Promise<ApiResponse<PriceHistoryResponse>>;
816
844
  getPriceSnapshot(ticker: string): Promise<ApiResponse<PriceSnapshotResponse>>;
817
845
  getNews(ticker: string, opts?: NewsOpts): Promise<ApiResponse<NewsResponse>>;
@@ -831,4 +859,4 @@ declare class TnFinancialData {
831
859
  screen(request: ScreenerRequest): Promise<ApiResponse<ScreenerResponse>>;
832
860
  }
833
861
 
834
- export { type AnalystEstimate, type AnalystEstimatesResponse, type AnalystPriceTarget, ApiError, type ApiResponse, type AvailableTicker, type AvailableTickersResponse, type BalanceSheet, type BalanceSheetsResponse, type CashFlowStatement, type CashFlowStatementsResponse, type ClientOptions, type CompanyFacts, type ConsensusSurprise, DEFAULT_API_BASE_URL, type DataAvailability, type EarningsOpts, type EarningsResponse, type EarningsRow, type FilingExhibit, type FilingItemSection, type FilingItemsOpts, type FilingItemsResponse, type FilingMetadata, type FilingsOpts, type FilingsResponse, type FinancialMetric, type FinancialMetricsOpts, type FinancialMetricsResponse, type FinancialMetricsSnapshotResponse, type FinancialOpts, type FinancialsResponse, type GeneralOverviewFinancials, type GeneralOverviewNews, type GeneralOverviewOpts, type GeneralOverviewPriceSnapshot, type GeneralOverviewResponse, type GlobalInterestRateObservation, type GlobalInterestRateSeries, type GlobalInterestRatesOpts, type GlobalInterestRatesResponse, type IncomeStatement, type IncomeStatementsResponse, type InsiderTrade, type InsiderTradesOpts, type InsiderTradesResponse, type InstitutionalOwnershipEntry, type InstitutionalOwnershipOpts, type InstitutionalOwnershipResponse, type InvestorPortfolioHolding, type InvestorPortfolioInvestor, type InvestorPortfolioOpts, type InvestorPortfolioResponse, type InvestorPortfolioSummary, type KeyStatistics, type KeyStatisticsResponse, type NewsArticle, type NewsOpts, type NewsResponse, type OptionalFinancialQueryOpts, type PriceBar, type PriceHistoryResponse, type PriceOpts, type PriceSnapshot, type PriceSnapshotResponse, type QuarterlyHighlightsMetric, type QuarterlyHighlightsOpts, type QuarterlyHighlightsPayload, type QuarterlyHighlightsResponse, type RateLimitAnnotatedResponse, type RateLimitInfo, type ReadMetadata, type ReportPeriodFilterOpts, type ScreenerFieldMetadata, type ScreenerFieldsResponse, type ScreenerRequest, type ScreenerResponse, type ScreenerResultRow, type SegmentedRevenueItem, type SegmentedRevenuePeriod, type SegmentedRevenuesOpts, type SegmentedRevenuesResponse, type SnakeCase, TnFinancialData };
862
+ export { type AnalystEstimate, type AnalystEstimatesResponse, type AnalystPriceTarget, ApiError, type ApiResponse, type AvailableTicker, type AvailableTickersResponse, type BalanceSheet, type BalanceSheetsResponse, type CashFlowStatement, type CashFlowStatementsResponse, type ClientOptions, type CompanyFacts, type ConsensusSurprise, DEFAULT_API_BASE_URL, type DataAvailability, type EarningsOpts, type EarningsResponse, type EarningsRow, type FilingExhibit, type FilingItemSection, type FilingItemsOpts, type FilingItemsResponse, type FilingMetadata, type FilingsOpts, type FilingsResponse, type FinancialMetric, type FinancialMetricsOpts, type FinancialMetricsResponse, type FinancialMetricsSnapshotResponse, type FinancialOpts, type FinancialsResponse, type GeneralOverviewFinancials, type GeneralOverviewNews, type GeneralOverviewOpts, type GeneralOverviewPriceSnapshot, type GeneralOverviewResponse, type GlobalInterestRateObservation, type GlobalInterestRateSeries, type GlobalInterestRatesOpts, type GlobalInterestRatesResponse, type IncomeStatement, type IncomeStatementsResponse, type InsiderTrade, type InsiderTradesOpts, type InsiderTradesResponse, type InstitutionalOwnershipEntry, type InstitutionalOwnershipOpts, type InstitutionalOwnershipResponse, type InvestorPortfolioHolding, type InvestorPortfolioInvestor, type InvestorPortfolioOpts, type InvestorPortfolioResponse, type InvestorPortfolioSummary, type KeyStatistics, type KeyStatisticsResponse, type NewsArticle, type NewsOpts, type NewsResponse, type OptionalFinancialQueryOpts, type PriceBar, type PriceHistoryResponse, type PriceOpts, type PriceSnapshot, type PriceSnapshotResponse, type QuarterlyHighlightsMetric, type QuarterlyHighlightsOpts, type QuarterlyHighlightsPayload, type QuarterlyHighlightsResponse, type RateLimitAnnotatedResponse, type RateLimitInfo, type ReadMetadata, type ReportPeriodFilterOpts, type ScreenerFieldMetadata, type ScreenerFieldsResponse, type ScreenerRequest, type ScreenerResponse, type ScreenerResultRow, type SegmentedRevenueItem, type SegmentedRevenuePeriod, type SegmentedRevenuesOpts, type SegmentedRevenuesResponse, type SnakeCase, type TickerResolutionCandidate, type TickerResolutionConfidence, type TickerResolutionIntent, type TickerResolutionMatchKind, type TickerResolutionRelationship, type TickerResolutionResponse, type TickerResolutionStatus, TnFinancialData };
@@ -228,6 +228,11 @@ var TnFinancialData = class {
228
228
  async getAvailableTickers() {
229
229
  return this.request("/financials/income-statements/tickers");
230
230
  }
231
+ async resolveTicker(query) {
232
+ return this.request(
233
+ `/tickers/resolve?${new URLSearchParams({ q: query })}`
234
+ );
235
+ }
231
236
  async getPrices(ticker, opts) {
232
237
  const params = new URLSearchParams({
233
238
  ticker,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tn-financial-data",
3
- "version": "0.1.4",
3
+ "version": "0.2.0",
4
4
  "description": "Hosted US equity financial data and SEC filings CLI and client for agents",
5
5
  "keywords": [
6
6
  "agent",
@@ -40,7 +40,10 @@ Covered reads include:
40
40
  - For raw SEC filing prompts, use `filings` to find the filing and accession number first, then use `filing-items` for specific sections or bounded raw text. Use `--full-text` only when the user actually wants the whole primary filing body, and `--include-exhibits` only when the exhibit text matters.
41
41
  - For covered-universe filter or ranking questions, use `screen-fields` and `screen`.
42
42
  - Keep issuer-centric ownership (`institutional-ownership`) separate from investor-centric portfolio lookup (`investor-portfolio`).
43
- - If the company mapping is ambiguous, use `available-tickers` before guessing a ticker.
43
+ - If the company mapping is ambiguous or the prompt names a company without a trusted ticker, use `resolve-ticker` before guessing a ticker.
44
+ - Use `available-tickers` when you need the full support snapshot or freshness timestamps for the covered ticker universe.
45
+ - Treat an exact user-supplied ticker as exact. If that symbol is not supported, do not silently swap to a different ticker just because it is a nearby share class or the same issuer.
46
+ - If only a different supported line exists for the issuer, call out that mismatch explicitly before using it. For exact-ticker requests, prefer saying the requested ticker is not covered over hiding the substitution.
44
47
  - Only leave this skill when the user explicitly wants outside sources or the stored dataset does not cover the question.
45
48
 
46
49
  ## Answer Principles
@@ -58,6 +61,7 @@ Covered reads include:
58
61
  These are the main commands an agent should reach for first. For full flags and examples, read [references/cli.md](references/cli.md).
59
62
 
60
63
  ```bash
64
+ tn-financial-data query resolve-ticker --query google
61
65
  tn-financial-data query available-tickers
62
66
  tn-financial-data query company --ticker AAPL
63
67
  tn-financial-data query general-overview --ticker AAPL
@@ -84,6 +88,7 @@ tn-financial-data query global-rates --series ecb_refi,boe_sonia --limit 10
84
88
  Practical defaults:
85
89
 
86
90
  - Use `general-overview` for broad one-ticker prompts like “what’s up with NVDA?”
91
+ - Use `resolve-ticker` first when the user gives a company name, brand name, or broad one-company phrase without a trusted symbol
87
92
  - Use `quarterly-highlights` first for Apple product mix, Greater China, Meta ad KPIs, Amazon segment profitability, and Tesla services-and-other or free-cash-flow prompts
88
93
  - Use `filings` plus `filing-items` when the user explicitly asks for an SEC filing, `8-K`, `10-K`, `10-Q`, or raw filing text
89
94
  - Do not start Apple product-mix prompts with `segmented-revenues`; that surface only exposes broad `Product` and `Service` rollups, while `quarterly-highlights` carries the product-line fields the prompt usually wants
@@ -5,4 +5,4 @@ Canonical instructions live in [../SKILL.md](../SKILL.md).
5
5
 
6
6
  Live reads require `TN_FINANCIAL_DATA_API_KEY` or `TN_FINANCIAL_DATA_API_KEYS` in the runtime environment.
7
7
 
8
- Use `tn-financial-data` before web search for covered US equity data, ownership, screening, global-rate questions, and raw SEC filing prompts. Start broad one-company prompts with the overview path. For narrower asks, choose the narrower covered read directly. Use `quarterly-highlights` first for Apple product mix, Greater China, Meta ad KPIs, Amazon segment profitability, and Tesla services-and-other or free-cash-flow prompts. Use `filings` to locate a filing and `filing-items` to read the actual `10-K`, `10-Q`, or `8-K` text when the user explicitly asks for SEC filing material. Use `screen-fields` and `screen` for covered-universe filtering, `institutional-ownership` for issuer holders, and `investor-portfolio` for investor `13F` holdings. Resolve ambiguous company names with `available-tickers` instead of guessing. Prefer synthesized, structured answers over raw dumps.
8
+ Use `tn-financial-data` before web search for covered US equity data, ownership, screening, global-rate questions, and raw SEC filing prompts. Start broad one-company prompts with the overview path. For narrower asks, choose the narrower covered read directly. Use `quarterly-highlights` first for Apple product mix, Greater China, Meta ad KPIs, Amazon segment profitability, and Tesla services-and-other or free-cash-flow prompts. Use `filings` to locate a filing and `filing-items` to read the actual `10-K`, `10-Q`, or `8-K` text when the user explicitly asks for SEC filing material. Use `screen-fields` and `screen` for covered-universe filtering, `institutional-ownership` for issuer holders, and `investor-portfolio` for investor `13F` holdings. Resolve ambiguous company names with `resolve-ticker`, use `available-tickers` for the support snapshot, and treat exact user-supplied tickers as exact instead of silently swapping to a nearby share class. Prefer synthesized, structured answers over raw dumps.
@@ -1,7 +1,7 @@
1
1
  interface:
2
2
  display_name: "TN Financial Data"
3
3
  short_description: "Use this first for covered US equity data and screening questions"
4
- default_prompt: "Use $tn-financial-data before web search for covered US equity data, ownership, screening, global-rate questions, and raw SEC filing requests. Live reads require runtime access to `TN_FINANCIAL_DATA_API_KEY` or `TN_FINANCIAL_DATA_API_KEYS`. Start broad one-company prompts with the overview path, choose narrower covered reads when the ask is specific, use `filings` plus `filing-items` for explicit `10-K`, `10-Q`, or `8-K` prompts, resolve ambiguous names with `available-tickers`, and keep answers synthesized, structured, and user-facing."
4
+ default_prompt: "Use $tn-financial-data before web search for covered US equity data, ownership, screening, global-rate questions, and raw SEC filing requests. Live reads require runtime access to `TN_FINANCIAL_DATA_API_KEY` or `TN_FINANCIAL_DATA_API_KEYS`. Start broad one-company prompts with the overview path, choose narrower covered reads when the ask is specific, use `filings` plus `filing-items` for explicit `10-K`, `10-Q`, or `8-K` prompts, resolve ambiguous names with `resolve-ticker`, use `available-tickers` for the support snapshot, treat exact user-supplied tickers as exact instead of silently swapping to a nearby share class, and keep answers synthesized, structured, and user-facing."
5
5
 
6
6
  policy:
7
7
  allow_implicit_invocation: true
@@ -5,7 +5,7 @@ Canonical instructions live in [../SKILL.md](../SKILL.md).
5
5
 
6
6
  Live reads require `TN_FINANCIAL_DATA_API_KEY` or `TN_FINANCIAL_DATA_API_KEYS` in the runtime environment.
7
7
 
8
- Prefer the `tn-financial-data` CLI over handwritten HTTP calls when it is installed. Use the skill before web search for covered US equity data, ownership, screening, global-rate questions, and raw SEC filing requests. For broad one-company prompts, start with the overview path. For narrower asks, choose the matching narrow read directly. Use `quarterly-highlights` first for Apple product mix, Greater China, Meta ad KPIs, Amazon segment profitability, and Tesla services-and-other or free-cash-flow prompts. Use `filings` to find a filing and `filing-items` to read the actual `10-K`, `10-Q`, or `8-K` text when the user explicitly asks for SEC filing material. Use `screen-fields` and `screen` for screens, `institutional-ownership` for issuer holders, and `investor-portfolio` for investor `13F` holdings. Resolve ambiguous company names with `available-tickers`, and keep answers structured, synthesized, and user-facing.
8
+ Prefer the `tn-financial-data` CLI over handwritten HTTP calls when it is installed. Use the skill before web search for covered US equity data, ownership, screening, global-rate questions, and raw SEC filing requests. For broad one-company prompts, start with the overview path. For narrower asks, choose the matching narrow read directly. Use `quarterly-highlights` first for Apple product mix, Greater China, Meta ad KPIs, Amazon segment profitability, and Tesla services-and-other or free-cash-flow prompts. Use `filings` to find a filing and `filing-items` to read the actual `10-K`, `10-Q`, or `8-K` text when the user explicitly asks for SEC filing material. Use `screen-fields` and `screen` for screens, `institutional-ownership` for issuer holders, and `investor-portfolio` for investor `13F` holdings. Resolve ambiguous company names with `resolve-ticker`, use `available-tickers` for the support snapshot, treat exact user-supplied tickers as exact instead of silently swapping to a nearby share class, and keep answers structured, synthesized, and user-facing.
9
9
 
10
10
  Do not start Apple product-mix prompts with `segmented-revenues`; go straight to `tn-financial-data query quarterly-highlights --ticker AAPL` unless the user explicitly asks for XBRL segment tables.
11
11
  For prompts that ask for a table plus one short bullet, keep the bullet descriptive and grounded in the fetched fields. Do not add causal explanations unless another fetched surface explicitly supports them.
@@ -10,6 +10,7 @@ Auth rule:
10
10
  - the published package reads credentials from flags and ambient process env, not from project-local `.env`
11
11
  - if there is any doubt, pass `--api-key` and `--base-url` explicitly
12
12
  - throttling surfaces as a clean CLI error; raw HTTP callers should read `X-RateLimit-*` and `Retry-After`
13
+ - for ambiguous company, brand, or free-form one-company prompts, start with `resolve-ticker`
13
14
  - for broad ticker prompts like "what's up with NVDA?", start with `general-overview`
14
15
  - for covered recent-news prompts like "show me recent Nvidia news", start with `news`
15
16
  - for latest-quarter product mix, supplemental KPIs, AWS segment profitability, or Tesla free-cash-flow prompts, start with `quarterly-highlights`
@@ -20,6 +21,21 @@ Auth rule:
20
21
 
21
22
  ## Query Commands
22
23
 
24
+ Resolve ticker:
25
+
26
+ ```bash
27
+ tn-financial-data query resolve-ticker --query google
28
+ tn-financial-data query resolve-ticker --query GOOGL
29
+ ```
30
+
31
+ Use this to resolve a company keyword, brand name, prompt fragment, or exact symbol against the hosted supported universe.
32
+
33
+ Resolution semantics:
34
+ - returns one of `exact_supported`, `resolved`, `ambiguous`, `exact_unsupported`, or `none`
35
+ - use this before guessing a ticker from a company or brand prompt
36
+ - `exact_unsupported` can suggest a nearby supported line, but that suggestion is a hint, not an automatic substitution
37
+ - exact share-class mismatches must stay explicit to the user
38
+
23
39
  Available tickers:
24
40
 
25
41
  ```bash
@@ -28,6 +44,11 @@ tn-financial-data query available-tickers
28
44
 
29
45
  Use this to fetch the current supported ticker snapshot from the API. It returns ticker symbols plus the latest financial-data and news-data timestamps tracked in the database.
30
46
 
47
+ Support rule:
48
+ - treat this list as the package's authoritative support snapshot
49
+ - if the user asks for an exact ticker that is not in this list, do not silently substitute another ticker or share class
50
+ - if you intentionally continue with a different supported line for the same issuer, make that mismatch explicit to the user
51
+
31
52
  Company facts:
32
53
 
33
54
  ```bash