Skip to content

code for cosine-sim in the docs is incomplete #3

@holtzermann17

Description

@holtzermann17

The definition of cosine-sim in the docs isn't a complete s-exp. Luckily the function is defined in examples.clj:

(defn cosine-sim
  [model word1 word2]
  (let [rawvecfn  #(.getRawVector (.forSearch model) %)
        [a1 a2] (map rawvecfn [word1 word2])]
    (i-stat/cosine-similarity a1 a2)))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions