<commit_before>defmodule PanWeb.CategoryPodcast do
  use PanWeb, :model
  alias Pan.Repo

  @primary_key false

  schema "categories_podcasts" do
    belongs_to(:podcast, PanWeb.Podcast, primary_key: true)
    belongs_to(:category, PanWeb.Category, primary_key: true)
  end

  def get_or_insert(category_id, podcast_id) do
    category_podcast =
      Repo.get_by(PanWeb.CategoryPodcast,
        category_id: category_id,
        podcast_id: podcast_id<commit_msg>changeset for category_podcast<commit_after>defmodule PanWeb.CategoryPodcast do
  use PanWeb, :model
  alias Pan.Repo

  @primary_key false

  schema "categories_podcasts" do
    belongs_to(:podcast, PanWeb.Podcast, primary_key: true)
    belongs_to(:category, PanWeb.Category, primary_key: true)
  end

  def changeset(struct, params \\ %{}) do
    struct
    |> cast(params, [:podcast_id, :category_id])
    |> validate_required([:podcast_id, :category_id])
  end

  def get_or_insert(category_id, podcast_id) do
    category_podcast =
      Repo.get_by(PanWeb.CategoryPodcast,
        category_id: category_id,
        podcast_id: podcast_id
{'fraction_non_alphanumeric': 0.08754512635379061, 'fraction_numerical': 0.0, 'mean_word_length': 4.2559241706161135, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, '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': '7376371', 'n_tokens_mistral': 376, 'n_tokens_neox': 372, 'n_words': 76}