blob: f958e6bde2e8bf3b6149d31e2842762bcc72c470 [file] [log] [blame]
---
active_crumb: Docs
layout: documentation
id: installation
---
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<div id="installation" class="col-md-8 second-column">
<section id="install">
<h2 class="section-title">Installation <a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2>
<p>
Apache NLPCraft requires <b>no special installation</b> operations:
</p>
<ul>
<li>If you <a href="/download.html">downloaded</a> binary ZIP archive -
<a target="asf" href="https://www.apache.org/dyn/closer.cgi#verify">verify</a> it and unzip it.
</li>
<li>If you <a href="/download.html">cloned</a> GitHub repository or downloaded source archive compile
it via <code>SBT</code> command:
<pre class="brush: scala, highlight: []">
$ sbt clean compile
</pre>
</li>
<li>Also you can use <code>maven</code> command and get same result:
<pre class="brush: scala, highlight: []">
$ mvn -B clean package -P stanford-core,examples
</pre>
</li>
</ul>
<p>
You are done 👍
</p>
<div class="bq warn">
<p>
<b>Minimal Java and Scala versions</b>
</p>
<p>
Starting with version <b>1.0.0</b> NLPCraft requires JDK 11+ and Scala 3.1.3.<br/>
</p>
</div>
</section>
<section id="new_project">
<h2 class="section-title">Create New Project <a href="#"><i class="top-link fas fa-fw fa-angle-double-up"></i></a></h2>
<p>
You can create new Scala projects in many ways - we recommend SBT
to accomplish this task. Make sure that <code>build.sbt</code> file has the following content:
</p>
<pre class="brush: js, highlight: [7]">
ThisBuild / version := "0.1.0-SNAPSHOT"
ThisBuild / scalaVersion := "3.1.3"
lazy val root = (project in file("."))
.settings(
name := "Your project",
version := "{{site.latest_version}}",
libraryDependencies += "org.apache.nlpcraft" % "nlpcraft" % "{{site.latest_version}}",
libraryDependencies += "org.scalatest" %% "scalatest" % "3.2.14" % "test"
)
</pre>
<p>
<b>NOTE: </b>make sure to use the latest versions of Scala and ScalaTest.
</p>
<p>
Check out <a href="first-example.html">First Example</a> for a quick deep dive.
</p>
</section>
</div>
<div class="col-md-2 third-column">
<ul class="side-nav">
<li class="side-nav-title">On This Page</li>
<li><a href="#install">Installation</a></li>
<li><a href="#new_project">New Project</a></li>
{% include quick-links.html %}
</ul>
</div>