anchor.diff:  %%      disable the advertisement.
   server({#ad{counter=Counter}=Ad, _}, Ads) ->
       %% Blocking threshold read for 5 advertisement impressions.
  -    {ok, _} = lasp:read(Counter, ?MAX_IMPRESSIONS),
  +    {ok, _} = lasp:read(Counter, {value, ?MAX_IMPRESSIONS}),
   
       %% Remove the advertisement.
       {ok, _} = lasp:update(Ads, {remove, Ad}, Ad),
  
positive.code:     %% Each client takes the full list of ads when it starts, and reads
      %% from the variable store.
      lists:map(fun(Id) ->
                  spawn_link(?MODULE, client, [Runner, Id, AdsWithContracts, undefined])
                  end, lists:seq(1, ?NUM_CLIENTS)).
  
  %% @doc Summarize results.
  
negative.code:                     wait_for_events(Count + 1, NumEvents)
              end
      end.
  
  %% @doc Periodically synchronize state with the server.
  synchronize(AdsWithContractsId, AdsWithContracts0, Counters0) ->
      %% Get latest list of advertisements from the server.
      {ok, {_, _, _, AdsWithContracts}} = lasp:read(AdsWithContractsId, AdsWithContracts0),
      AdList = ?SET:value(AdsWithContracts),
      Identifiers = [Id || {#ad{counter=Id},_} <- AdList],
  
      lager:info("AdsWithContracts: ~p", [AdsWithContracts]),
  
      %% Refresh our dictionary with any new values from the server.
      %%
      %% 1.) Given the list of new values from the server...
      %% 2.) ...fill in any holes in our dictionary accordingly.
      %%
      RefreshFun = fun({#ad{counter=Ad}, _}, Acc) ->
                        case dict:is_key(Ad, Acc) of
                            false ->
                                {ok, {_, _, _, Counter}} = lasp:read(Ad, undefined),
                                dict:store(Ad, Counter, Acc);
                            true ->
                                Acc
                        end
                end,
      Counters = lists:foldl(RefreshFun, Counters0, AdList),
  
      %% Bind our latest values with the server process.
      %%
      %% 1.) Send our dictionary of values to server.
      %% 2.) Server computes a bind operation with the incoming value.
      %% 3.) Server returns the merged value to the client.
      %%
      SyncFun = fun(Ad, Counter0, Acc) ->
                      {ok, {_, _, _, Counter}} = lasp:bind(Ad, Counter0),
                      % lager:info("Synchronizing counter ~p: ~p => ~p", [Ad, Counter0, Counter]),
                      case lists:member(Ad, Identifiers) of
                          true ->
                              dict:store(Ad, Counter, Acc);
                          false ->
                              Acc
                      end
                end,
      Counters1 = dict:fold(SyncFun, dict:new(), Counters),
  
      lager:info("Identifiers: ~p", [Identifiers]),
      lager:info("Counters1: ~p", [Counters1]),
  
      {ok, AdsWithContracts, Counters1}.
  