<commit_before>"use strict"

/**
 * model utility functions:
 *    - convert from/to client/backend data representations
 */
define([ 'jquery', 'model/diff', 'model/graph' ], function($, model_diff, model_graph) {

    /**
     * read by adapting from backend format
     */
    function adapt_format_read_node(n_raw) {
        var ret;

        ret = $.extend({
            'type' : n_raw['__type'].toLowerCase(), // discard all
            // labels except
            'state' : 'temp',
        }, n_raw);

        delete ret.__label_set;

        return ret;
    }

    /**
     * write by adapting to backend format
     */
    function adapt_format_write_node(n_raw) {
        var ret = $.extend({
            '__type' : n_raw.type,<commit_msg>model/util: rm unused dep: model/graph<commit_after>"use strict"

/**
 * model utility functions:
 *    - convert from/to client/backend data representations
 */
define(['jquery', 'model/diff'], 
function($, model_diff) {

    /**
     * read by adapting from backend format
     */
    function adapt_format_read_node(n_raw) {
        var ret;

        ret = $.extend({
            'type' : n_raw['__type'].toLowerCase(), // discard all
            // labels except
            'state' : 'temp',
        }, n_raw);

        delete ret.__label_set;

        return ret;
    }

    /**
     * write by adapting to backend format
     */
    function adapt_format_write_node(n_raw) {
        var ret = $.extend({
            '__type' : n_raw.type,
{'fraction_non_alphanumeric': 0.1318607764390897, 'fraction_numerical': 0.0, 'mean_word_length': 2.0202020202020203, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '7281493', 'n_tokens_mistral': 452, 'n_tokens_neox': 437, 'n_words': 110}