Serial model and credit risk: put the change back in the sample

Understanding how multi-source history enters a risk model in terms of time available, long range sequences and forwards.

System Chapter . StepCollate in 2 Graphics6 self-measurement3 First-hand sources
Start Body
Learning objectives and first steps4 objectives • 3 first fixes

Try to do it after reading

  • Define observation window and forecast target
  • Hand-counting memory and sequence influence
  • Division multi-source variable long sequence and mask
  • Distinguishing risk projections from counterfactual policy

Suggested first

  • Monitoring learning and data splitting
  • Thrust shape
  • Basic gradient and sigmoid

The same total, not necessarily the same process of change

Both users had two different types of events in the observation window, but one had recently been concentrated and the other had occurred earlier. Simple numbers may be the same, but the trends vary. The sequence model attempts to encode sequence, spacing and context so that risk projections can use information other than static aggregations. Whether it is truly helpful requires a reliable static baseline, off-the-shelf validation and mitigation comparison.

The credit mandate also requires a strict limitation on the time available. No transactions beyond the point of time, no follow-up status, and no premature targets can be mixed into history. All events, scores and users of this paper are synthetic settings, do not describe the true client or disclose any internal model benefits. 2026-10-29 Check RNN course, GRU original and Transformer original.

Let's write the sample into a time problem

Sets the observation point t to enter the history available as t with the goal of a well-defined risk event for the future H days. A user may have multiple observation cross-sections, but they are relevant; The training certification cannot treat the adjacent cross section as a fully independent sample. Clear rules are required for label windows, delayed data reporting, closed or unobserved orders.

Each event contains not only content vector x, but also time stampes, intervals relative to t, sources and missing marks. Multiple sources do not necessarily share the same time particle size: a single session, a day count and a single order can be different sequences. (b) The forced alignment of lines would create a non-existent synchronous relationship; The event is defined within each source before the interactive mode is decided.

Different rhythms of multi-source events before common observation pointsThe three time axes show behaviour, order and attribute updates, with different number and time of events, followed by a tab window that is prohibited for input.Behavior SeriesOrder sequenceProperties UpdateObservation tFuture objectivesDo not enter input
Each point on the line is a synthetic event. Article k from different sources does not have to occur at the same time.

How to remember history with a minimum push

You don't need a complete neural network. Take the mark and pushhₖ=0.5hₖ₋₁+0.5xₖ, Initial h ₀=0。 It mixes old memories with current events. For sequences [10,1], the status is 0.5, 0.25, 0.625; The same two ones and zeroes, arranged in [0,1,1], are in order of 0, 0.5, 0.75. The numbers are the same, and ultimately they represent a difference.

hk=0.5hk−1+0.5xk

This is a smoother equivalent to a fixed decay, not a complete GRU. GRU allows the door to learn to retain the ratio according to input and old state and to introduce candidate status; Agreements may be made for the placement of the different pools or for the calculation of candidates. LSTM also maintains the memory state alone. The door is understood by stating “what factor is multiplied by the old state” and not by extrapolating the direction of retention or oblivion solely under the name.

Two forward tracks of the same total number of eventsThe real line is the status zero-five-five-two-five-two-five and the dot-one-one status zero-five-five-five.Article 1Article 2Article 3Dashed: 0,1,1 → 0.75Solid lines: 1,0,1 § 0.625
The vertical axis is a synthetic hidden state, not a risk probability. The thrust factor is fixed and only indicates the order.
# 标准 Python,已执行;固定递推,不是训练好的GRU。
def encode(events, valid=None):
state, history = 0.0, []
if valid is None:
valid = [True]*len(events)
for value, keep in zip(events,valid):
if keep:
state = .5*state+.5*value
history.append(state)
return state, history
assert encode([1,0,1])[0] == .625
assert encode([0,1,1])[0] == .75
assert encode([1,0,1,0],[True,True,True,False])[0] == .625
assert encode([1,0,1,0])[0] == .3125

Distinguish long data between zero and non-existent

Batch input constant[B,T,D], with a length or active position mask. The true event value is zero, which is different from the zero added to make up. Add a padding zero after this example and continue to push, which would cause an error to 0.3125; The correct practice is to retain 0.625 or read the final validity status through a clear length. Attention encoder, padding key, padding query have a different function from the final loss mask.

The missing value cannot be added to the zero without an explanation. There may be different meanings to the fact that a source is not recorded at all, a record field is missing and zero is observed. The inclusion of missing markings, source markings and time intervals can help to express differences, but these markings themselves must be available when predicted. Normalization statistics estimate only in the context of training that the scales from different sources cannot be combined without inspection.

There are several assumptions about multi-source integration

(b) It can be collated first by source codes, allowing each encoder to process its length and semantic content; The event could also be coded in conjunction with the source and timing; You can also adjust the sequence on condition of static properties. The choice should address operational availability and data characteristics rather than simply pursuing structural complexities. It would be preferable to preserve the source of the integration: whether removing a particular road remains stable and whether the users missing a particular road are damaged.

Transformer directly combines different positions through attention, but location information, time design and correct mask is still required, without automatic understanding of the real time interval. The longer the sequence is not the better: earlier history may be old, noiseier and costing more. Users should be identified when comparing window length, cut-off direction, event sampling and source coverage.

The risk profile is not a causal response to offer

Historical data are used to predict a given result, learning about the linkages under the current data generation mechanism. If... credit limit The period or price was chosen by strategy, model input offer And then it doesn't automatically get "change." offer What's going to happen? Decides that the counterfactual strategy requires the identification of assumptions, experimental information or other designs and the examination of overlapping overlays. High AUC does not alone prove the benefits of a change of strategy.

The assessment should be differentiated, calibrated, stable and missing source coverage by extra-temporal and mass slicing reports; The online version also covers data delays and reasoning. Sequence models are only candidate methods, and simple statistics, tree models and static depth networks should be retained for comparison. The use of historical sequences should not lead to the assertion that problems have not been studied by any previous person.

Self-measurement and interpretation

There's two sequences. Why is the final state different?

(a) Fixed push gives greater weight to newer events and therefore the sequence influences the outcome; The count does not keep this information.

After [10,1] add padding zero, why not continue to be true?

Continuing to push will reduce 0.625 to 0.3125, adding non-existent information. mask or length should keep the state.

Can Article 5 events from different sources be directly aligned to the location?

Typically, they may not be time- and particle-scale-specific. This alignment needs to be supported by time and the semantics of events.

Could an event that occurred before t, but which was not stored after t, be used for a t simulation?

It is not possible that simulation deployments need to be filtered according to the time available and not just the time of the incident.

Can offer, as input, predict the effects of any new offer?

Can't. Historical policy choices are biased, insufficiently covered and mixed to limit counterfactual interpretation and the association prediction does not automatically equal causal effect.

Total AUC upgrade, can you ignore the missing user from the source?

No, you can't. The overall figure may be dominated by large sample populations and coverage, calibration and missing source slices should be checked.

Continue to go back to Data Severation and Leakage and compare how the weight of Attention becomes a new expression. Standard Python extension and padding calculations were implemented, GRU, Transformer or business risk models were not trained, and no back-up benefits were validated.

Sources and reconciliations

Definitions, methods and interfaces are available.

  1. Dive into Deep Learning — Recurrent Neural Networks
  2. Learning Phrase Representations using RNN Encoder-Decoder
  3. Attention Is All You Need

Figures and calculations are reorganized according to this chapter. Mathematical measurements, framework operations and real business effects are described separately in the body of the text.

← Back to the knowledge directory
Ask Max Ask about this site
Ask Max ↗

Opening the assistant…

Paper figure

Photo comments

LEAVE A NOTE

About this photograph

Connecting to the discussion board…

    Comments become public after moderation. You can delete your own comments from this browser.
    No email is required. Clearing cookies prevents this browser from claiming earlier comments.

    MAX WANG / INDEX

    Find something

    Enter a keyword, or explore the directory below.