danielfrg

danielfrg / word2vec / 0.3.2

word2vec

Royalty Free API Calls - 1,388
word2vec functions for similarity and analogies
Language
Python 3.x
Permissions
The Apache License is a permissive free software license written by the Apache Software Foundation (ASF). Learn More

Run an Example

Input
Output
[
  [
    [
      "dogs",
      0.8680489915680536
    ],
    [
      "puppy",
      0.8106428352360294
    ],
    [
      "pit_bull",
      0.7803960342611623
    ]
  ],
  [
    [
      "queen",
      0.26689835890816027
    ],
    [
      "monarch",
      0.23208332083114688
    ],
    [
      "princess",
      0.22131306095983244
    ]
  ]
]

Install and Use

Install

Install the Algorithmia CLI client by running:

curl -sSLf https://algorithmia.com/install.sh | sh

Then authenticate by running:

algo auth
# Enter API Key: YOUR_API_KEY
CLI Install Docs

Use



algo run danielfrg/word2vec/0.3.2 -d '[
  {
    "similar": {
      "word": "dog", "n": 3
    }
  },
  {
    "analogy": {
      "pos": ["king", "woman"],
      "neg": ["man"],
      "n": 3
    }
  }
]' --timeout 300
  
CLI Docs