<commit_before><?php

namespace App\Providers;

use App\Http\Transformers\TransformerInterface;
use App\Services\SerializerService;
use Illuminate\Http\Request;
use Illuminate\Support\ServiceProvider;

/**
 * Provide 2 macro's to generate a response based on predefined transformers
 *
 * Class ApiResponseServicePRofiver
 * @package App\Providers
 */
class ApiResponseServiceProvider extends ServiceProvider
{

    public function boot()
    {
        $serializer = $this->app->make('SerializerService');
        $headers = [
            'Access-Control-Allow-Origin' => '*',
            'Cache-Control' => 'max-age=900, public',
        ];

        response()->macro(
            'item',
            function (
                TransformerInterface $transformer,
                $item,<commit_msg>Added Vary header to API responses.<commit_after><?php

namespace App\Providers;

use App\Http\Transformers\TransformerInterface;
use App\Services\SerializerService;
use Illuminate\Http\Request;
use Illuminate\Support\ServiceProvider;

/**
 * Provide 2 macro's to generate a response based on predefined transformers
 *
 * Class ApiResponseServicePRofiver
 * @package App\Providers
 */
class ApiResponseServiceProvider extends ServiceProvider
{

    public function boot()
    {
        $serializer = $this->app->make('SerializerService');
        $headers = [
            'Access-Control-Allow-Origin' => '*',
            'Cache-Control' => 'max-age=900, public',
            'Vary' => 'Accept-Encoding, Accept',
        ];

        response()->macro(
            'item',
            function (
                TransformerInterface $transformer,
                $item,
{'fraction_non_alphanumeric': 0.11157768446310738, 'fraction_numerical': 0.004799040191961607, 'mean_word_length': 2.7232142857142856, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 14, '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': '5618811', 'n_tokens_mistral': 447, 'n_tokens_neox': 438, 'n_words': 99}