You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nothing currently sources edibility. species_facts holds 3edible_part rows (source pfaf) and 71 vegetable rows (source merged_from_synonym, i.e. copied from a synonym, not sourced at all). There is no PFAF crawler in lib/crawlers/; those 3 rows are residue.
Ranked by coverage-per-effort:
1. Kew — World Checklist of Useful Plant Species
~40,000 species with use categories including Human Food, published open with a DOI. By far the best ratio available, and the decisive advantage: it is keyed on WCVP accepted names, which we already ingest (lib/crawlers/wcvp.rb). Name reconciliation — the part that usually eats the budget on a job like this — is close to free here.
Gives a coarse boolean-grade signal (this species is used as human food), not parts. That is the coverage layer.
2. Plants For A Future
~7,000 species with an Edibility Rating 0-5, the edible part, and preparation notes — precisely the three columns #354 defines, which is why the rating scale in that issue is PFAF's rather than one of ours. This is the depth layer: fewer species, but the only source that fills preparation and caution at scale.
Licence needs settling before ingest — PFAF's database terms are not a standard open licence. Check, and if it does not permit redistribution, do not ingest it: cite it as a link-out instead. Same discipline as every source under #318.
3. USDA GRIN Taxonomy
Economic-use records for cultivated and crop-adjacent species. US-government public domain, stable identifiers, good API. Strongest on the cultivated side of #358.
4. OpenFarm
Already wired (lib/crawlers/openfarm.rb). Growing guides for crops — feeds cultivated and the planting_* fields, not edibility per se. Cheap because the crawler exists.
5. USDA PLANTS palatable_human
old_species carries the column from the original import. It is empty in the dev restore (0 true, 0 false, 0 null — the table itself is empty there), so verify against prod before counting on it. If prod has values it is a few thousand US species for free; if not, drop this line.
Never overwrite a filled value. Promote into empty fields only; disagreements go to the corrections queue for a human. Identical rule to Promote TRY trait facts into empty species columns, with attribution #328, and it matters more here: a source that wrongly asserts edibility is worse than a gap.
Licence recorded before ingest, no exceptions. An edibility dataset we cannot legally redistribute is a liability, not an asset.
Acceptance
Per-source: ForeignSource with licence + citation, a fact count, and a sample of 20 records verified by hand against the source.
Part of #350. Feeds #354, #355 and #356.
Nothing currently sources edibility.
species_factsholds 3edible_partrows (sourcepfaf) and 71vegetablerows (sourcemerged_from_synonym, i.e. copied from a synonym, not sourced at all). There is no PFAF crawler inlib/crawlers/; those 3 rows are residue.Ranked by coverage-per-effort:
1. Kew — World Checklist of Useful Plant Species
~40,000 species with use categories including Human Food, published open with a DOI. By far the best ratio available, and the decisive advantage: it is keyed on WCVP accepted names, which we already ingest (
lib/crawlers/wcvp.rb). Name reconciliation — the part that usually eats the budget on a job like this — is close to free here.Gives a coarse boolean-grade signal (this species is used as human food), not parts. That is the coverage layer.
2. Plants For A Future
~7,000 species with an Edibility Rating 0-5, the edible part, and preparation notes — precisely the three columns #354 defines, which is why the rating scale in that issue is PFAF's rather than one of ours. This is the depth layer: fewer species, but the only source that fills
preparationandcautionat scale.Licence needs settling before ingest — PFAF's database terms are not a standard open licence. Check, and if it does not permit redistribution, do not ingest it: cite it as a link-out instead. Same discipline as every source under #318.
3. USDA GRIN Taxonomy
Economic-use records for cultivated and crop-adjacent species. US-government public domain, stable identifiers, good API. Strongest on the
cultivatedside of #358.4. OpenFarm
Already wired (
lib/crawlers/openfarm.rb). Growing guides for crops — feedscultivatedand theplanting_*fields, not edibility per se. Cheap because the crawler exists.5. USDA PLANTS
palatable_humanold_speciescarries the column from the original import. It is empty in the dev restore (0 true, 0 false, 0 null — the table itself is empty there), so verify against prod before counting on it. If prod has values it is a few thousand US species for free; if not, drop this line.Scope
treflehq/trefle-crawlers(private) and writeSpeciesFactrows withsource,source_record_id,source_url,evidence_type: reported. Same contract as the TRY import (Promote TRY trait facts into empty species columns, with attribution #328).ForeignSourcerow per source with its licence and citation text (Expose each upstream source's licence in the API (sources[].licence) #318), the promotion migrator that projects the strongest active fact onto the columns and the Replace the edible_part bitmask with sourced part rows: preparation, caution, and a 0-5 food-use rating #354/Toxicity is an enum filled on 0 of 489k species: populate it, and model it per part like edibility #355 tables, and alib/checks/divergence report where two sources disagree on the same species.Acceptance
ForeignSourcewith licence + citation, a fact count, and a sample of 20 records verified by hand against the source.Checks::PlausibleValues.Touches:
treflehq/trefle-crawlers(private),app/workers/migrators/,lib/checks/,db/seeds,spec/