Replace nt with nq in various places throughout

Manually change testdata.nt to testdata.nq.
This commit is contained in:
kortschak 2014-07-25 14:56:08 +09:30
parent 3995d3dd57
commit fae860f08e
7 changed files with 20 additions and 20 deletions

View file

@ -1,6 +1,6 @@
{ {
"Arch": "amd64 386", "Arch": "amd64 386",
"Os": "linux darwin windows", "Os": "linux darwin windows",
"ResourcesInclude": "README.md,static,templates,LICENSE,AUTHORS,CONTRIBUTORS,docs,cayley.cfg.example,30kmoviedata.nt.gz,testdata.nt", "ResourcesInclude": "README.md,static,templates,LICENSE,AUTHORS,CONTRIBUTORS,docs,cayley.cfg.example,30kmoviedata.nq.gz,testdata.nq",
"ConfigVersion": "0.9" "ConfigVersion": "0.9"
} }

View file

@ -72,13 +72,13 @@ cayley> graph.Vertex("dani").Out("follows").All()
For somewhat more interesting data, a sample of 30k movies from Freebase comes in the checkout. For somewhat more interesting data, a sample of 30k movies from Freebase comes in the checkout.
``` ```
./cayley repl --dbpath=30kmoviedata.nt.gz ./cayley repl --dbpath=30kmoviedata.nq.gz
``` ```
To run the web frontend, replace the "repl" command with "http" To run the web frontend, replace the "repl" command with "http"
``` ```
./cayley http --dbpath=30kmoviedata.nt.gz ./cayley http --dbpath=30kmoviedata.nq.gz
``` ```
And visit port 64210 on your machine, commonly [http://localhost:64210](http://localhost:64210) And visit port 64210 on your machine, commonly [http://localhost:64210](http://localhost:64210)
@ -90,13 +90,13 @@ The default environment is based on [Gremlin](http://gremlindocs.com/) and is si
You'll notice we have a special object, `graph` or `g`, which is how you can interact with the graph. You'll notice we have a special object, `graph` or `g`, which is how you can interact with the graph.
The simplest query is merely to return a single vertex. Using the 30kmovies.nt dataset from above, let's walk through some simple queries: The simplest query is merely to return a single vertex. Using the 30kmoviedata.nq dataset from above, let's walk through some simple queries:
```javascript ```javascript
// Query all vertices in the graph, limit to the first 5 vertices found. // Query all vertices in the graph, limit to the first 5 vertices found.
graph.Vertex().GetLimit(5) graph.Vertex().GetLimit(5)
// Start with only one vertex, the literal name "Humphrey Bogart", and retreive all of them. // Start with only one vertex, the literal name "Humphrey Bogart", and retrieve all of them.
graph.Vertex("Humphrey Bogart").All() graph.Vertex("Humphrey Bogart").All()
// `g` and `V` are synonyms for `graph` and `Vertex` respectively, as they are quite common. // `g` and `V` are synonyms for `graph` and `Vertex` respectively, as they are quite common.

View file

@ -1,6 +1,6 @@
{ {
"database": "mem", "database": "mem",
"db_path": "30k.nt", "db_path": "30kmoviedata.nq.gz",
"read_only": true, "read_only": true,
"load_size": 10000, "load_size": 10000,
"gremlin_timeout": 10 "gremlin_timeout": 10

View file

@ -28,13 +28,13 @@ You can repeat the `--db` and `--dbpath` flags from here forward instead of the
First we load the data. First we load the data.
```bash ```bash
./cayley load --config=cayley.cfg.overview --triples=30kmoviedata.nt.gz ./cayley load --config=cayley.cfg.overview --triples=30kmoviedata.nq.gz
``` ```
And wait. It will load. If you'd like to watch it load, you can run And wait. It will load. If you'd like to watch it load, you can run
```bash ```bash
./cayley load --config=cayley.cfg.overview --triples=30kmoviedata.nt.gz --alsologtostderr ./cayley load --config=cayley.cfg.overview --triples=30kmoviedata.nq.gz --alsologtostderr
``` ```
And watch the log output go by. And watch the log output go by.

View file

@ -430,11 +430,11 @@ func TestParse(t *testing.T) {
} }
} }
// This is a sample taken from 30kmovies.nq. // This is a sample taken from 30kmoviedata.nq.
// It has intentional defects: // It has intentional defects:
// The second comment is inset one psace and // The second comment is inset one psace and
// the second line after that comment is blank. // the second line after that comment is blank.
var document = `# first 10 lines of 30kmovies.nq var document = `# first 10 lines of 30kmoviedata.nq
_:100000 </film/performance/actor> </en/larry_fine_1902> . _:100000 </film/performance/actor> </en/larry_fine_1902> .
_:100001 </film/performance/actor> </en/samuel_howard> . _:100001 </film/performance/actor> </en/samuel_howard> .
_:100002 </film/performance/actor> </en/joe_palma> . _:100002 </film/performance/actor> </en/joe_palma> .
@ -445,7 +445,7 @@ _:100006 </film/performance/actor> </en/emil_sitka> .
_:100007 </film/performance/actor> </en/christine_mcintyre> . _:100007 </film/performance/actor> </en/christine_mcintyre> .
_:100008 </film/performance/actor> </en/moe_howard> . _:100008 </film/performance/actor> </en/moe_howard> .
_:100009 </film/performance/actor> </en/larry_fine_1902> . _:100009 </film/performance/actor> </en/larry_fine_1902> .
#last ten lines of 30kmovies.nq #last ten lines of 30kmoviedata.nq
</guid/9202a8c04000641f800000001473e673> <name> "Bill Fishman" . </guid/9202a8c04000641f800000001473e673> <name> "Bill Fishman" .
</guid/9202a8c04000641f800000001473e673> <type> </people/person> . </guid/9202a8c04000641f800000001473e673> <type> </people/person> .

9
testdata.nq Normal file
View file

@ -0,0 +1,9 @@
<alice> <follows> <bob> .
<bob> <follows> <alice> .
<charlie> <follows> <bob> .
<dani> <follows> <charlie> .
<dani> <follows> <alice> .
<alice> <is> "cool" .
<bob> <is> "not cool" .
<charlie> <is> "cool" .
<dani> <is> "not cool" .

View file

@ -1,9 +0,0 @@
alice follows bob .
bob follows alice .
charlie follows bob .
dani follows charlie .
dani follows alice .
alice is cool .
bob is "not cool" .
charlie is cool .
dani is "not cool" .