Skip to content

GaryB432/wikibase-console

Repository files navigation

Wikibase Console

Just My Happy Project GitHub branch check runs MIT License

Command line app for exploring the Wikibase API.

Most of my repos are private but this one is in front of my loyal followers (you know who you are 😎).

Goals

Be a repo that

Non-Goals

  • Duplicate functionality of official Wikibase tools
  • Be a real tool that people will actually use

Common development commands

  • pnpm dlx prettier . -w
  • pnpm exec eslint
  • pnpm run build
  • pnpm run lint
  • pnpm run test
  • tsx src/main.ts

References

maxlath/wikibase-sdk: JS utils functions to query a Wikibase instance and simplify its results

Wikibase/API - MediaWiki

wikidata.org/w/api.php?action=wbgetentities&ids=Q33725&format=json&languages=en&props=info%7Clabels

wikidata.org/w/api.php?action=wbgetentities&ids=Q125121451&format=json&languages=en&props=info%7Clabels

Wikidata and the Semantic Web

Wikidata:List of properties/all in one table - Wikidata

Help:Data type - Wikidata

CONOR.SI ID - Wikidata

More

Wikidata Property Explorer

All pages (Property namespace) - Wikidata

graph TD
  subgraph ClaimStructure
    Claim -- has one --> MainSnak
    Claim -- can have many --> Qualifier
    Claim -- can have many --> Reference
    Claim[Claim]
    MainSnak["Snak (Main)"]
    Qualifier[Qualifier]
    Reference[Reference]
  end

  subgraph SnakDetails
    MainSnak -- has one --> Property
    MainSnak -- has one --> DataValue
    Property[Property]
  end

  subgraph ValueTypes
    DataValue[DataValue]
    DataValue -- is a --> String
    DataValue -- is a --> WikipediaId
    String[String]
    WikipediaId[WikipediaId]
  end

Loading

Albert Einstein was born at Ulm

graph TD
  subgraph ClaimStructure
    Claim["Claim"]
    Claim -- has one --> MainSnak
    Claim -- can have many --> Qualifier
    Claim -- can have many --> Reference
  end

  subgraph SnakDetails
    MainSnak["Snak (Main)"]
    MainSnak -- has one --> Property
    MainSnak -- has one --> DataValue
    Property["Property"]
  end

  subgraph ValueTypes
    DataValue["DataValue"]
    DataValue -- is a --> EntityId
  end

  subgraph ExampleClaim
    Claim -- refers to --> EinsteinEntity
    Claim -- describes property --> BornAtProperty
    MainSnak -- has value --> UlmEntity
    EinsteinEntity["Albert Einstein (Q937)"]
    BornAtProperty["P19: Born at"]
    UlmEntity["Ulm (Q20440)"]
  end
  %%Styling
  style Claim fill:#bbf,stroke:#555,stroke-width:2px
  style MainSnak fill:#ffb,stroke:#555,stroke-width:2px
  style Property fill:#bbf,stroke:#555,stroke-width:2px
  style DataValue fill:#bbf,stroke:#555,stroke-width:2px
  style Qualifier fill:#bbf,stroke:#555,stroke-width:2px
  style Reference fill:#bbf,stroke:#555,stroke-width:2px
  style String fill:#eee,stroke:#555,stroke-width:2px
  style WikipediaId fill:#eee,stroke:#555,stroke-width:2px
  style EntityId fill:#eee,stroke:#555,stroke-width:2px
  style EinsteinEntity fill:#eee,stroke:#000,stroke-width:2px
  style BornAtProperty fill:#eee,stroke:#000,stroke-width:2px
  style UlmEntity fill:#eee,stroke:#000,stroke-width:2px

Loading

About

ESM command line app for exploring the Wikibase API

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors