Skip to main content

Gram grammar for tree-sitter

Project description

tree-sitter-gram

A tree-sitter grammar for gram notation.

Gram is a subject-based notation for structured data.

If this is an object:

{
  "name":"Andreas",
  "roles":["author"]
}

Implicitly the object is a person. To become a subject, the implicit information can be explicit.

As a subject:

(:Person {
  name: "Andreas",
  roles: ["author"]
})

Learn more about gram at the gram-data github org notation.

Editor Support

This repository includes editor integrations for syntax highlighting and language support:

  • Zed Editor - Full syntax highlighting and language support
  • More editors coming soon! Contributions welcome.

See editors/README.md for installation instructions and available features.

Language Bindings

Tree-sitter bindings are available for multiple languages:

  • Node.js: npm install @gram-data/tree-sitter-gram
  • Rust: Available via Cargo.toml
  • Python: Install via pip install .
  • Go: Import from this repository
  • Swift: Available via Swift Package Manager
  • C: Build with included Makefile

Development

Generate the parser after grammar changes:

npx tree-sitter generate
npx tree-sitter test

Run language binding tests:

npm test                    # Node.js bindings
cargo test                  # Rust bindings
python -m pytest           # Python bindings
make test                   # C bindings

See DEVELOP.md for detailed development guidelines.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tree_sitter_gram-0.2.0.tar.gz (18.9 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

tree_sitter_gram-0.2.0-cp39-abi3-win_arm64.whl (15.9 kB view details)

Uploaded CPython 3.9+Windows ARM64

tree_sitter_gram-0.2.0-cp39-abi3-win_amd64.whl (17.0 kB view details)

Uploaded CPython 3.9+Windows x86-64

tree_sitter_gram-0.2.0-cp39-abi3-musllinux_1_2_x86_64.whl (25.5 kB view details)

Uploaded CPython 3.9+musllinux: musl 1.2+ x86-64

tree_sitter_gram-0.2.0-cp39-abi3-musllinux_1_2_aarch64.whl (26.4 kB view details)

Uploaded CPython 3.9+musllinux: musl 1.2+ ARM64

tree_sitter_gram-0.2.0-cp39-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl (27.3 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64manylinux: glibc 2.28+ ARM64

tree_sitter_gram-0.2.0-cp39-abi3-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (25.5 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.28+ x86-64manylinux: glibc 2.5+ x86-64

tree_sitter_gram-0.2.0-cp39-abi3-macosx_11_0_arm64.whl (15.1 kB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

tree_sitter_gram-0.2.0-cp39-abi3-macosx_10_9_x86_64.whl (14.4 kB view details)

Uploaded CPython 3.9+macOS 10.9+ x86-64

File details

Details for the file tree_sitter_gram-0.2.0.tar.gz.

File metadata

  • Download URL: tree_sitter_gram-0.2.0.tar.gz
  • Upload date:
  • Size: 18.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for tree_sitter_gram-0.2.0.tar.gz
Algorithm Hash digest
SHA256 d658b40e9e65f3ed3952496f22f9735dfe5ec6835454ed4a5923ddf0f5c20ecb
MD5 2761e619e5aba5c94887b838d2d10139
BLAKE2b-256 8e160f8b6fc1d954aea4af8ebc142939b9962eab3199892cfbe5824c518ef5ba

See more details on using hashes here.

File details

Details for the file tree_sitter_gram-0.2.0-cp39-abi3-win_arm64.whl.

File metadata

File hashes

Hashes for tree_sitter_gram-0.2.0-cp39-abi3-win_arm64.whl
Algorithm Hash digest
SHA256 0f3bd7a0ce46a4f39a8ff97b6c1de586f6608cfaeaf5422e4974a4a3b6e979d3
MD5 a48eaa59591ee541081945e21d8964c9
BLAKE2b-256 85858b94eef67af8aff6c8243969cf1625f68fa0e28313c3d2610dee8e5c2d81

See more details on using hashes here.

File details

Details for the file tree_sitter_gram-0.2.0-cp39-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for tree_sitter_gram-0.2.0-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 ee04a1441fe9849f4decd2fa898ef0f55c08019fa0574053c65cbeb0ec5d0417
MD5 e40021076554c6e208af15e245beafba
BLAKE2b-256 6154561364e89de712510bacf19e1a9f19db4808d7108618358fed53e64036db

See more details on using hashes here.

File details

Details for the file tree_sitter_gram-0.2.0-cp39-abi3-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_gram-0.2.0-cp39-abi3-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 0b3e38a486c437f431e35d7a22622752ae4ca837dd3c55eb2ccb2ff6acafdfc2
MD5 6b27f1ebc6491f5100d3311c00def581
BLAKE2b-256 81cb2e50e0b2c49a28a5ce065a9b027a3449713411e3a696b8c7fbc3e8f5d2c1

See more details on using hashes here.

File details

Details for the file tree_sitter_gram-0.2.0-cp39-abi3-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for tree_sitter_gram-0.2.0-cp39-abi3-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 975a07f51e79cd98663803a561beff3c5413ddd7b19a6edd6532c788b661eb25
MD5 ac06ee22ceb9d501ef18d2e45786f9bd
BLAKE2b-256 f3697022691c368c27f1a22a2cb867f99f04edcf646078d528771bdf44b53746

See more details on using hashes here.

File details

Details for the file tree_sitter_gram-0.2.0-cp39-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for tree_sitter_gram-0.2.0-cp39-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 005eb6b69cda793f0a19f0eef4ae5987aa411df6390fc4fbc8d57a66e25a51db
MD5 660f4f3de71b5a4d17acaae7151f47a6
BLAKE2b-256 937bd8b7c33ef329dfea32257161f7f35a71f512a100032fafb24426f979aba3

See more details on using hashes here.

File details

Details for the file tree_sitter_gram-0.2.0-cp39-abi3-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_gram-0.2.0-cp39-abi3-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 0eeededecc0da0b6a6460a06bc9af531c3aebb4e0628c2a72e71c550632d1b31
MD5 2767ff4397c26afe35b7d606d726566f
BLAKE2b-256 a534217072a6e1087a58304ab3aec2d00daf44d8ef13a998d655a71a8897256e

See more details on using hashes here.

File details

Details for the file tree_sitter_gram-0.2.0-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for tree_sitter_gram-0.2.0-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ada9c8cc66a8fbbacfb408b42678ec99a5b16aa0e12c8354a56e1512751b0e33
MD5 616f95c04f36ec59ec8c255013677d48
BLAKE2b-256 b1d05e69f4c6861a00cee47d608c9e7b5e912ea8786bd32ad493a3a67aec69e8

See more details on using hashes here.

File details

Details for the file tree_sitter_gram-0.2.0-cp39-abi3-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for tree_sitter_gram-0.2.0-cp39-abi3-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 a4aa4cac6cc4513afd325f5e0bf42ff171d79fea6c2f6eb614220a50cc796ffd
MD5 f189637675054238f0fa80cdd75bf163
BLAKE2b-256 ea9a73d3ce1c7033918d3ddec4860cdf93917744f4485683b7acfcf2c9fc9b5d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page