{"id":19504762,"url":"https://github.com/nice-digital/ttl2jsonld","last_synced_at":"2026-05-15T06:40:02.088Z","repository":{"id":82181872,"uuid":"43675973","full_name":"nice-digital/ttl2jsonld","owner":"nice-digital","description":null,"archived":false,"fork":false,"pushed_at":"2016-03-29T13:00:37.000Z","size":32,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":29,"default_branch":"master","last_synced_at":"2025-01-08T10:45:24.310Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nice-digital.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-10-05T09:39:19.000Z","updated_at":"2016-03-29T13:00:22.000Z","dependencies_parsed_at":null,"dependency_job_id":"197f2b4f-b898-4bc3-a5a9-2ad76d68cb7c","html_url":"https://github.com/nice-digital/ttl2jsonld","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nice-digital%2Fttl2jsonld","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nice-digital%2Fttl2jsonld/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nice-digital%2Fttl2jsonld/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nice-digital%2Fttl2jsonld/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nice-digital","download_url":"https://codeload.github.com/nice-digital/ttl2jsonld/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240754366,"owners_count":19852189,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-10T22:27:08.882Z","updated_at":"2026-05-15T06:39:57.066Z","avatar_url":"https://github.com/nice-digital.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ttl2jsonld\n\n\u003e Extract JSON-LD graphs from a stardog triple store\n\n## Getting Started\n\nIf you haven't used [Grunt](http://gruntjs.com/) before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](http://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:\n\n```shell\nnpm install https://github.com/nhsevidence/ttl2jsonld.git --save\n```\n\nOnce the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:\n\n```js\ngrunt.loadNpmTasks('ttl2jsonld');\n```\n\n## TTL2JSONLD task\n_Run this task with the `grunt ttl2jsonld` command._\n\nTask targets, files and options may be specified according to the grunt [Configuring tasks](http://gruntjs.com/configuring-tasks) guide.\n\n### Options\n\n#### helpers\nType: `Object`\nDefault: `{}`\n\nThis provides access to helper methods, such as text formatters, within the Handlebars templates. \n\n_Note: Please, consider the map function before creating complex template logic._\n\n#### context\nType: `Object`  \nDefault: `{}`\n\nJSON-LD graph context object.\n\n#### vocab\nType: `String`\nDefault: ''\n\nBase vocabulary for the JSON-LD graphs.\n\n#### sync\nType: `Boolean`\nDefault: 'false'\n\nForce syncronous execution becasue Stardog handles too many requests poorly.\n\n#### server\nType: `String`\nDefault: ''\n\nStardog server URL\n\n#### db\nType: `String`\nDefault: ''\n\nStardog DB name to execute against\n\n#### username\nType: `String`\nDefault: ''\n\nUsername for the DB user to execute against\n\n#### password\nType: `String`\nDefault: ''\n\nPassword for the DB user to execute against\n\n\n### Usage Example\n\n```js\nttl2jsonld: {\n  models: {\n    options: {\n      server: 'snarl://stardog',\n      db: 'myDb',\n      username: 'admin',\n      password: 'admin',\n      vocab:  'http://schema.org/',\n      context: {\n        \"rdf\": \"http://www.w3.org/1999/02/22-rdf-syntax-ns#\",\n        \"dct\": \"http://purl.org/dc/terms/\",\n        \"owl\": \"http://www.w3.org/2002/07/owl#\",\n        \"rdfs\": \"http://www.w3.org/2000/01/rdf-schema#\"\n      }\n    },\n    reasoning: true,\n    model: '...',\n    type: 'owl:Thing',\n    dest: './models',\n  }\n}\n```\n\n###### Options\n\nOptions can be specified for all `ttl2jsonld` tasks and for each `ttl2jsonld:target` just like in other Grunt tasks.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnice-digital%2Fttl2jsonld","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnice-digital%2Fttl2jsonld","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnice-digital%2Fttl2jsonld/lists"}