Sha256: a369dfb7ae3caad6d4f2def88bc38597afba371b46219c27a1bcde85e8101bce

Contents?: true

Size: 502 Bytes

Versions: 1

Compression:

Stored size: 502 Bytes

Contents

require 'rbbt/ner/annotations'

module Relationship
  attr_accessor :terms, :segment_types
  include Segment
  def self.annotate(string, offset = nil, terms = nil)
    string.extend PPI
    string.offset = offset unless offset.nil?
    string.terms = terms unless terms.nil?
    string
  end

  def html
    text = <<-EOF
<span class='Relationship'\
>#{ self }</span>
    EOF
    text.chomp
  end

  def html_with_entities(*types)
    annotations.values_at(*types).each do |segments|
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rbbt-text-0.5.0 lib/rbbt/ner/annotations/relations.rb