Repository navigation
Improve MCP answers and data quality ahead of the public launch - #241
Merged
Merged
Conversation
…ency names
- A venue's size is the number of listings of its own country, so venues full of
foreign lines no longer win as the largest main exchange abroad (Airbus: AIR.PA).
- A line abroad whose symbol shape almost only receipts have is a receipt (B3's
'34' BDRs), and abroad a line with the share's ISIN beats one without.
- Asking for funds or money markets says they are no longer maintained and that the
Python package still has them.
- A currency's name finds the pairs with its code ('japanese yen').
A numbered ticker (Yahoo's SOL1) is dropped when the unnumbered coin is in the file with the same name and the same website (or none), keeping the twin's homepage. Removes SOL1, HNT1, DOT1, STX1 and UNI3.
- Reviewed the categories of every large and mega cap company's primary listing against its business description and applied 347 corrections to all its listings (same ISIN or name), e.g. Philips and Siemens Healthineers to Medical Devices & Supplies, RELX and Wolters Kluwer to Professional Services, Visa-like processors to Payments & Specialty Finance, Brookfield Corporation to Capital Markets. - Corrected countries that matched neither the listing's exchange nor its ISIN where the company description names the headquarters (e.g. Malaysian companies marked Japan), plus reviewed fixes (Zoetis, Fortis, MercadoLibre). - Fixed names and blanked summaries that described another company. - Lines abroad of a share whose home listings are all delisted are delisted too. - Relisted companies the Nasdaq Trader directory still lists (Jacobs Solutions, Brink's, Centerspace and others) and removed two warrants.
A ticker identifies one security on every German exchange, so a Berlin, Dusseldorf, Munich, Hamburg or Hanover line without an ISIN takes the ISIN, full name and blank family, categories and summary of the live Xetra or Frankfurt line with the same ticker (4,430 lines, e.g. VWCE.BE 'VANG.FTSE A.W. DLA').
…tries - Ferrovial SE (registered in the Netherlands since 2023): one name, country and classification on every line, the ISIN on its German lines, and its Euronext Amsterdam listing FER.AS (NL0015001FS8). - Toyota Boshoku makes seats and interiors: Auto Parts. Experian's SIX line is headquartered in Ireland like its other lines. - Blank countries are filled where the company description's headquarters matches the exchange's country or the ISIN country (323 listings).
- Berlin, Dusseldorf, Munich, Hamburg, Hanover and Stuttgart ETF lines take the categories every other listing of the fund agrees on (770 lines); a leveraged or short fund keeps Derivatives. - Siemens Limited (India) is Large Cap, not its parent's Mega Cap.
Xetra lists the ETFs tradable in Germany, so a Berlin, Dusseldorf, Munich, Hamburg, Hanover, Stuttgart or Frankfurt line without an ISIN whose ticker Xetra doesn't list is a mutual fund, not an ETF (16,786 lines such as 'DEKA-BAV FONDS'). Lines whose name says ETF, ETC, ETN or UCITS are kept, except funds of ETFs.
The weekly US update now compares the NASDAQ, NYSE and NYSE American equities with the Nasdaq Trader symbol directory: a row the directory no longer lists is delisted, a delisted share it lists again under the same name is relisted, and the lines abroad of a share whose home listings are all delisted follow. More than 3% delistings in one run are skipped as a bad download. The first run delisted 803 rows (expired SPAC units and warrants, acquired companies, redeemed preferreds), relisted 15 and delisted 77 lines abroad.
273 listings without an industry take the one classification all other listings with the same ISIN agree on.
Redeemable NCDs, rights issues, leveraged products, price or total return indices,
Nordic knock-out, stop-loss and mini certificates ('KO 1(39'), subscription
warrants by series ('TO3') and names ending in 'Wts' are not company shares. The
38 such equities rows are removed, with a warrant and a silver reserve receipt
whose names don't show it.
Each smaller company's primary listing without an industry, or whose listings disagree, was classified from its business description (rows whose description was too vague, shells and diversified holdings stay blank). The result is applied to all listings of the company: 3,233 newly classified companies and 706 resolved conflicts, 6,244 rows in all.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes from a full test of the MCP server before its public launch: more than 80 tool calls on a local server running main, re-run after each round of fixes on the corrected data.
MCP server and package
Data
Sources: the companies' own business descriptions and headquarters in the database, company filings for the reviewed corrections, the Nasdaq Trader symbol directory and Euronext Amsterdam's listing of Ferrovial SE.
Added after review
scripts/equities/status_model.py):The first run delisted 803 rows (expired SPAC units and warrants, acquired companies, redeemed preferreds), relisted 15 and delisted 77 lines abroad.
check_non_share): redeemable NCDs, rights issues, leveraged products, listed indices, Nordic knock-out and stop-loss certificates, and Swedish subscription warrants (TO3). The 40 such rows are removed.Still open
Checks: full test suite (401 passed), identifier gate, categories check,
remove_non_shares.py --dry-run(0 rows), black and ruff.After merging, CI regenerates
compression/; the MCP server needs a redeploy and a cache clear to serve the new data.