<commit_before>require 'uuid'

class NirvanaHQ

  def post payload
    result = `curl -sX POST 'https://api.nirvanahq.com/?api=json&authtoken=#{@token}' -d '#{payload}'`  
  end

  # final form tbd. For now, have it parse out the results of the request, and send that along as a hash obj
  def everything
    raw = JSON.parse(`curl -sX GET 'https://api.nirvanahq.com/?api=rest&authtoken=#{@token}&method=everything&since=0'`)
    raw['results']
  end

  # task_details a hash with the task info  
  def add task_details

    #prepare payload
    now = Time.now.to_i    
    defaults = {
      "method" => "task.save",<commit_msg>include appid identifying as gem<commit_after>require 'uuid'

class NirvanaHQ

  def post payload
    result = `curl -sX POST 'https://api.nirvanahq.com/?api=json&appid=gem&authtoken=#{@token}' -d '#{payload}'`  
  end

  # final form tbd. For now, have it parse out the results of the request, and send that along as a hash obj
  def everything
    raw = JSON.parse(`curl -sX GET 'https://api.nirvanahq.com/?api=rest&appid=gem&authtoken=#{@token}&method=everything&since=0'`)
    raw['results']
  end

  # task_details a hash with the task info  
  def add task_details

    #prepare payload
    now = Time.now.to_i    
    defaults = {
      "method" => "task.save",
{'fraction_non_alphanumeric': 0.12798766383962992, 'fraction_numerical': 0.0015420200462606013, 'mean_word_length': 3.4, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3354963', 'n_tokens_mistral': 464, 'n_tokens_neox': 441, 'n_words': 129}