Skip to content
This repository has been archived by the owner on Apr 20, 2022. It is now read-only.

Commit

Permalink
updating documentation
Browse files Browse the repository at this point in the history
Former-commit-id: ac863de
  • Loading branch information
lfoppiano committed Jan 28, 2018
1 parent 3fd5637 commit 8ab80de
Show file tree
Hide file tree
Showing 4 changed files with 79 additions and 15 deletions.
4 changes: 2 additions & 2 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,14 @@ _Warning_: Some quota and query limitation apply to the demo server! If you are

## Latest version

The latest stable release of GROBID is version ```0.5.0```. As compared to previous version ```0.4.3```, this version brings:
The latest stable release of GROBID is version ```0.5.1```. This version brings:

+ Migrate from maven to gradle for faster, more flexible and more stable build, release, etc.
+ Usage of Dropwizard for web services
+ Move the Grobid service manual to [readthedocs](http://grobid.readthedocs.io/en/latest/Grobid-service/)
+ (thanks to @detonator413 and @lfoppiano for this release! future work in versions 0.5.* will focus again on improving PDF parsing and structuring accuracy)

New in previous release ```0.4.3```:
New in previous release ```0.4.4```:

+ New models: f-score improvement on the PubMed Central sample, bibliographical references +2.5%, header +7%
+ New training data and features for bibliographical references, in particular for covering HEP domain (INSPIRE), arXiv identifier, DOI and url (thanks @iorala and @michamos !)
Expand Down
6 changes: 3 additions & 3 deletions doc/Grobid-docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ The process for fetching and running the image is (assuming docker is installed

- Pull the image from docker HUB
```bash
> docker pull lfoppiano/grobid:0.5.0
> docker pull lfoppiano/grobid:0.5.1
```

- Run the container (note the new version running on 8070):

```bash
> docker run -t --rm -p 8080:8070 -p 8081:8071 lfoppiano/grobid:0.5.0
> docker run -t --rm -p 8080:8070 -p 8081:8071 lfoppiano/grobid:0.5.1
```

(alternatively you can also get the image ID)
```bash
> docker images | grep lfoppiano/grobid | grep 0.4.2
> docker images | grep lfoppiano/grobid | grep 0.5.1
> docker run -t --rm -p 8080:8070 -p 8081:8071 $image_id_from_previous_command
```

Expand Down
71 changes: 67 additions & 4 deletions doc/Grobid-java-library.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,85 @@
The [RESTful API](Grobid-service.md) provides a simple and efficient way to use and deploy GROBID. As an alternative, the present page explains how to embed Grobid directly in your Java application.
The [RESTful API](Grobid-service.md) provides a simple and efficient way to use and deploy GROBID.
As an alternative, the present page explains how to embed Grobid directly in your Java application.

After [building the project](Install-Grobid.md), two core jar files are created: grobid-core-`<current version>`.onejar.jar and grobid-core-`<current version>`.jar
After [building the project](Install-Grobid.md), two core jar files are created: grobid-core-`<current version>`.onejar.jar
and grobid-core-`<current version>`.jar

A complete working **maven** project example of usage of GROBID Java API can be found here: [https://github.com/kermitt2/grobid-example](https://github.com/kermitt2/grobid-example). The example project is using GROBID Java API for extracting header metadata and citations from a PDF and output the results in BibTex format.
A complete working **maven** project example of usage of GROBID Java API can be found here: [https://github.com/kermitt2/grobid-example](https://github.com/kermitt2/grobid-example).
The example project is using GROBID Java API for extracting header metadata and citations from a PDF and output the results in BibTex format.

An example project for using GROBID in an **ant** project is available [here](https://github.com/kermitt2/grobid-test-ant).

## Using maven

When using maven, you need to include in your pom file the path to the Grobid jar file, for instance as follow (replace `0.5.0` by the valid `<current version>`):
GROBID releases are uploaded on the [grobid bintray](https://bintray.com/rookies/maven/grobid) repository.

You need to add the following snippet in your pom.xml in order to configure it:

```xml
<profiles>
<profile>
<repositories>
<repository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>bintray-rookies-maven</id>
<name>bintray</name>
<url>https://dl.bintray.com/rookies/maven</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>bintray-rookies-maven</id>
<name>bintray-plugins</name>
<url>https://dl.bintray.com/rookies/maven</url>
</pluginRepository>
</pluginRepositories>
<id>bintray</id>
</profile>
</profiles>
<activeProfiles>
<activeProfile>bintray</activeProfile>
</activeProfiles>
</settings>
```


In this way you after configuring such repository the dependencies will be automatically managed.

If you want to work on a SNAPSHOT development version, you need to include in your pom file the path to the Grobid jar file,
for instance as follow (replace `0.5.0` by the valid `<current version>`):

```xml
<dependency>
<groupId>org.grobid.core</groupId>
<artifactId>grobid</artifactId>
<version>0.5.0</version>
<scope>system</scope>
<systemPath>${project.basedir}/lib/grobid-core-0.5.0.jar</systemPath>
</dependency>
```

## Using gradle

Add the following snippet in your gradle.build file:

```groovy
repositories {
maven {
url "https://dl.bintray.com/rookies/maven"
}
}
```

and add the Grobid dependency as well:
```
compile 'org.grobid:grobid-core:0.5.1'
compile 'org.grobid:grobid-trainer:0.5.1'
```


## API call
Expand Down
13 changes: 7 additions & 6 deletions doc/Install-Grobid.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@

###Latest stable release

The [latest stable release](https://github.com/kermitt2/grobid#latest-version) of GROBID is version ```0.5.0``` which can be downloaded as follow:
The [latest stable release](https://github.com/kermitt2/grobid#latest-version) of GROBID is version ```0.5.1``` which can be downloaded as follow:
```bash
> wget https://github.com/kermitt2/grobid/archive/0.5.0.zip
> unzip 0.5.0.zip
> wget https://github.com/kermitt2/grobid/archive/0.5.1.zip
> unzip 0.5.1.zip
```

or using the [docker](Grobid-docker.md) container.

###Current development version
The current development version is ```0.5.1-SNAPSHOT```, which can be downloaded from GitHub and built as follow:
The current development version is ```0.6.0-SNAPSHOT```, which can be downloaded from GitHub and built as follow:

Clone source code from github:
```bash
Expand All @@ -29,7 +29,7 @@ Or download directly the zip file:

##Build GROBID

**Please make sure that grobid is installed in a path with no parent directories containing spaces.**
**Please make sure that Grobid is installed in a path with no parent directories containing spaces.**

###Build GROBID with Gradle

Expand All @@ -44,6 +44,7 @@ By default, tests are ignored. For building the project and running the tests, u

##Use GROBID

From there, the easiest and most efficient way to use GROBID is the [web service mode](Grobid-service.md). You can also use the tool in [batch mode](Grobid-batch.md) or integrate it in your Java project via the [Java API](Grobid-java-library.md).
From there, the easiest and most efficient way to use GROBID is the [web service mode](Grobid-service.md).
You can also use the tool in [batch mode](Grobid-batch.md) or integrate it in your Java project via the [Java API](Grobid-java-library.md).


0 comments on commit 8ab80de

Please sign in to comment.