Code Monkey home page Code Monkey logo

external-tools's Introduction

External Tools

This repository contains stand-alone tools that are independent of the main OpenCog source tree. Examples of the kinds of tools that might be added to this repository:

  • visualization tools for viewing AtomSpace contents
  • workbench type tools for controlling and monitoring OpenCog (e.g. http://wiki.opencog.org/w/OpenCog_Workbench)
  • performance, diagnostic, and statistical reporting tools

These external tools will typically interface with OpenCog via the REST API (http://wiki.opencog.org/w/Web_interface), and be developed as web applications (though this is not a requirement).

As of October 2017, the default and preferred visualization app is the AtomSpaceExplorer. All previous visualization attempts have been moved to the Obsolete sub-folder for posterity.

external-tools's People

Contributors

amebel avatar dagiopia avatar eddiemonroe avatar elggem avatar leungmanhin avatar linas avatar manisabri avatar misgeatgit avatar ngeiswei avatar sambod50 avatar sanuj avatar sebastianruder avatar selameab avatar skoumas avatar strangetcy avatar tanksha avatar tscottj avatar tseg avatar ykal avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

external-tools's Issues

"npm start" crashes after successful "npm install"

don't know what other info is helpful (list of package versions is insanely long). here is log file:

0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'start' ]
2 info using [email protected]
3 info using [email protected]
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info lifecycle [email protected]~prestart: [email protected]
6 info lifecycle [email protected]~start: [email protected]
7 verbose lifecycle [email protected]~start: unsafe-perm in lifecycle true
8 verbose lifecycle [email protected]~start: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/home/mjsd/oc/external-tools/AtomSpaceExplorer/node_modules/.bin:/usr/local/cuda-9.0/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
9 verbose lifecycle [email protected]~start: CWD: /home/mjsd/oc/external-tools/AtomSpaceExplorer
10 silly lifecycle [email protected]~start: Args: [ '-c', 'ng serve' ]
11 silly lifecycle [email protected]~start: Returned: code: 1  signal: null
12 info lifecycle [email protected]~start: Failed to exec start script
13 verbose stack Error: [email protected] start: `ng serve`
13 verbose stack Exit status 1
13 verbose stack     at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:280:16)
13 verbose stack     at emitTwo (events.js:125:13)
13 verbose stack     at EventEmitter.emit (events.js:213:7)
13 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack     at emitTwo (events.js:125:13)
13 verbose stack     at ChildProcess.emit (events.js:213:7)
13 verbose stack     at maybeClose (internal/child_process.js:927:16)
13 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
14 verbose pkgid [email protected]
15 verbose cwd /home/mjsd/oc/external-tools/AtomSpaceExplorer
16 verbose Linux 4.4.0-97-generic
17 verbose argv "/usr/local/bin/node" "/usr/local/bin/npm" "start"
18 verbose node v8.4.0
19 verbose npm  v5.4.2
20 error code ELIFECYCLE
21 error errno 1
22 error [email protected] start: `ng serve`
22 error Exit status 1
23 error Failed at the [email protected] start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]

fetch only works correctly on first application

when i went to to reload the atomspace by pressing fetch either no nodes appear or there is part of a node stuck in the upper left corner behind the play button. i have to close the tab and open a new one to get a new dump from the atomspace.

large networks get squashed to the sides of the browser view port

the repulsion force ends up squashing almost everything against the edges of the window. can the boundaries be made repulsive as well to spread everything out in the space?
attached are 2 scheme files, one is an ensemble of boolean models generated by applying moses to a gene expression data set (115 atoms): oovc_ensemble.scm.txt
and one is a set of three ensembles (including the atoms in the first file) and definitions of the predicates in the ensembles using geneNodes (~ 1000 atoms): moses-models.scm.txt

the first is a definite use case and the second is pushing the boundaries of usefulness. i think visualization of 100s or thousands of nodes could be useful to show large scale structure but is a secondary use case.

Please bring back ability to specify port # for glimpse atomspace viewer

You used to be able to specify the port # the app would listen to with the startup command, e.g.,

./startServer.sh 9000   #for port 9000

But with the recent change in the startup command, it looks like you can no longer do this.

This is important especially because the default port for the glimpse app (8000) conflicts with a port used by the Hanson Robotics HEAD stack for it's web user interface (also 8000). Perhaps we should also change the default port for the atomspace viewer.

glitch with repeated entry of "v" in url box

for example with the url http://localhost:5000/api/v1.1/atoms, the first time entering there is no problem, but when i retype and get to the "v" the version window pops up as if i typed control-v.

Module build failed

On Ubuntu 16.04 npm install works fine, but trying npm start -- --port 3030 leads to the following error:

ERROR in ./node_modules/css-loader?{"sourceMap":false,"importLoaders":1}!./node_modules/postcss-loader?{"ident":"postcss"}!./node_modules/sass-loader/lib/loader.js?{"sourceMap":false,"precision":8,"includePaths":[]}!./src/theme.scss
Module build failed: Error: ENOENT: no such file or directory, scandir '~/opencog/external-tools/AtomSpaceExplorer/node_modules/node-sass/vendor'
    at Object.fs.readdirSync (fs.js:904:18)
    at Object.getInstalledBinaries (~/opencog/external-tools/AtomSpaceExplorer/node_modules/node-sass/lib/extensions.js:128:13)
    at foundBinariesList (~/opencog/external-tools/AtomSpaceExplorer/node_modules/node-sass/lib/errors.js:20:15)
    at foundBinaries (~/opencog/external-tools/AtomSpaceExplorer/node_modules/node-sass/lib/errors.js:15:5)
    at Object.module.exports.missingBinary (~/opencog/external-tools/AtomSpaceExplorer/node_modules/node-sass/lib/errors.js:45:5)
    at module.exports (~/opencog/external-tools/AtomSpaceExplorer/node_modules/node-sass/lib/binding.js:15:30)
    at Object.<anonymous> (~/opencog/external-tools/AtomSpaceExplorer/node_modules/node-sass/lib/index.js:14:35)
    at Module._compile (module.js:643:30)
    at Object.Module._extensions..js (module.js:654:10)
    at Module.load (module.js:556:32)
    at tryModuleLoad (module.js:499:12)
    at Function.Module._load (module.js:491:3)
    at Module.require (module.js:587:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (~/opencog/external-tools/AtomSpaceExplorer/node_modules/sass-loader/lib/loader.js:3:14)
    at Module._compile (module.js:643:30)
 @ ./src/theme.scss 4:14-186
 @ multi ./src/styles.css ./src/theme.scss

webpack: Failed to compile.

node -v is v8.9.4, and npm -v is 5.6.0

Cant install AtomSpaceExplorer

It uses semantic-ui and it can not be installed with any recent version of gulp and node and many other packages. I worked with this node package before, it's abandoned and has issues ... ( kind of a nightmare tbh)

Invalid atom syntax (SUMO)

I get a syntax error when I try to import likes of below implication rule from SUMO to Atomspace

(=>
  (and
     (domain ?REL ?NUMBER ?CLASS1)
     (domain ?REL ?NUMBER ?CLASS2))
  (or
     (subclass ?CLASS1 ?CLASS2)
     (subclass ?CLASS2 ?CLASS1))
)

ERROR: In procedure cog-new-link:
Throw to key C++-EXCEPTION' with args ("cog-new-link" "Invalid Atom syntax:

(OrLink
(InheritanceLink
(VariableNode "?CLASS1") ; [49929d9688eabc67][1]
(VariableNode "?CLASS2") ; [1bdad0b3e1d92a86][1]
) ; [ea88a87e2b7f8980][1]
(InheritanceLink
(VariableNode "?CLASS2") ; [1bdad0b3e1d92a86][1]
(VariableNode "?CLASS1") ; [49929d9688eabc67][1]
) ; [f6134a8c23788e31][1]
) ; [d80ddb80465d3195][-1] (/opncog/atomspace/opencog/atoms/base/ClassServer.cc:138)
Function args:
((InheritanceLink
(VariableNode "?CLASS1")
(VariableNode "?CLASS2")
)
(InheritanceLink
(VariableNode "?CLASS2")
(VariableNode "?CLASS1")
)
)")'.

It's about the consequent of the implication rule.
I'll be happy to fix it but I'm still very new to the whole thing
Creating the whole OrLink in guile throws the same exception, is something wrong with this syntax?

add arrowheads to show "incoming set"

adding an arrowhead to the edges of hyperlinks indicating the "incoming" direction would aid in visual parsing of the hypergraph structure, as messily indicated in this screenshot:
incoming set arrowheads

SUMO importer improvements

Overview

I propose here a series of changes, with various degrees of confidence
depending on the cases, for the sumo importer. I will update this page
as measure as more changes come to my attention.

SUMO instance should be translated as Member not Inheritance

Currently expressions like

(instance A B)

are translated as

Inheritance
  A
  B

The problem is that then the instance can be used (in SUMO) as
object, function, relationship, etc, and not generally as subclass.

For instance inverse in file Merge.kif

(instance inverse BinaryPredicate)
(inverse husband wife)

is translated as

(InheritanceLink (stv 1.000000 1.000000)
  (ConceptNode "inverse" (stv 0.010000 1.000000)) ; [7690791279017416557][1]
  (ConceptNode "BinaryPredicate" (stv 0.010000 1.000000)) ; [6410280537314717277][1]
) ; [11635137124257520146][1]
(EvaluationLink (stv 1.000000 1.000000)
  (PredicateNode "inverse" (stv 0.100000 1.000000)) ; [7691424597714988965][1]
  (ListLink
    (ConceptNode "husband" (stv 0.010000 1.000000)) ; [7336481066825120890][1]
    (ConceptNode "wife" (stv 0.010000 1.000000)) ; [2015412845701781066][1]
  ) ; [13937302832202503127][1]
) ; [11051686663622052499][1]

creating 2 inconsistent terms for inverse, one being a concept, the other
being a predicate. Instead it should be

(MemberLink (stv 1.000000 1.000000)
  (PredicateNode "inverse" (stv 0.010000 1.000000)) ; [7690791279017416557][1]
  (ConceptNode "BinaryPredicate" (stv 0.010000 1.000000)) ; [6410280537314717277][1]
) ; [11635137124257520146][1]
(EvaluationLink (stv 1.000000 1.000000)
  (PredicateNode "inverse" (stv 0.100000 1.000000)) ; [7691424597714988965][1]
  (ListLink
    (ConceptNode "husband" (stv 0.010000 1.000000)) ; [7336481066825120890][1]
    (ConceptNode "wife" (stv 0.010000 1.000000)) ; [2015412845701781066][1]
  ) ; [13937302832202503127][1]
) ; [11051686663622052499][1]

The link type of the instance (PredicateNode, etc) will have to be
determined by looking at the SUMO subclass it belongs to (for instance
an instance of BinaryPredicate will be a PredicateNode). This is
more difficult than what is currently done but more semantically
sound.

Forall, exists, etc

[EDIT: the following is probability a bad idea and needs to be more carefully thought].

I noticed that in most cases SUMO forall are followed by => which
could be translated into a mere ImplicationScopeLink where the
variables in the forall would become the variables in the
ImplicationScopeLink. It could also be a ForAllLink wrapping an
ImplicationLink over TVs, but I'd rather avoid this because I fear
it would lead to confusions and misuses. Using the
ImplicationScopeLink is simpler and more alligned with the usual
conditional probabilistic interpretation.

Although since SUMO is crisp, unless we start attaching probabilities
(Ben, you mentioned wordnet and word2vec, but I don't understand
specifically how that would be done), using an ImplicationScopeLink
is good enough anyway. Then for the cases when SUMO forall is
not followed by =>, I would suggest to use an AverageLink or
equivalently a LambdaLink, as a opposed to a ForAllLink, because
the semantics of AverageLink/LambdaLink is closer to
ImplicationScopeLink (it is merely an ImplicationScopeLink with
the universe as implicant) than the semantics of ForAllLink as
defined in the PLN book. But then to be consistent the SUMO exists
should not be translated into ExistsLink but instead rewritten as

Not
  LambdaLink
    <vardecl>
    Not
      <body>

which is kinda messy. One might then want to define an alternative
exists link type equivalent to that, maybe called
AverageBasedExistsLink (although it's an awkward name). Or use the
existing ExistsLink but it should be clear that the semantics, in
the non-crisp cases anyway, is different than the one defined in the
PLN book.

Support SUMO row variables

Row variables (starting with @) should be translated into GlobNode
or wrapped in a ListLink, or have its type defined as such.

notes on current commit of AtomSpaceExplorer

this is a mix of comments, bugs & TODOs based on hooking up the ase to an atomspace being used for the biology project mozi.

there needs to be a cap on the number of atoms to load: my first try was on an atomspace with 4 million nodes and it tried to load them all, filling up ram and then bogging down filling up swap disk! i had to shut down the cogserver to get it to stop. maybe this is more of an opencog rest api problem.

when i went to to reload the atomspace by pressing fetch either no nodes appear or there is part of a node stuck in the upper left corner behind the play button. i have to close the tab and open a new one to get a new dump from the atomspace.

it would be nice to have the history list back in the url line so i don't have to keep retyping the url!

the url is http://localhost:5000/api/v1.1/atoms and after the first time entered, when i retype and get to the "v" the version window pops up as if i typed control-v.

i successfully loaded an atomspace of 115 atoms from an ensemble of moses models. the repulsion force ends up squashing almost everything against the edges of the window. can the boundaries be made repulsive as well to spread everything out in the space?

let me know what else i can test or what info you need to improve feedback.

thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.